//
// sub_4DC698 from 0x4dc698 to 0x4dc6d8 (64 bytes)
//
// 176 xrefs:
// > SetTextPopup::textChanged @ 0x8c47a4
// > GJWriteMessagePopup::FLAlert_Clicked @ 0x8c48c8
// > SetFolderPopup::setTextPopupClosed @ 0x8c4cc8
// > SetColorIDPopup::colorSelectClosed @ 0x8c4ea8
// > GJMessagePopup::onRemove @ 0x8c5000
// > GJWriteMessagePopup::onClearBody @ 0x8c515c
// > SetFolderPopup::valueChanged @ 0x8c52dc
// > SetFolderPopup::valueChanged @ 0x8c5308
// > UpdateAccountSettingsPopup::updateSettingsFailed @ 0x8c5464
// > UpdateAccountSettingsPopup::updateSettingsFinished @ 0x8c55e4
// > GJMessagePopup::onBlock @ 0x8c582c
// > GJMessagePopup::onBlock @ 0x8c5858
// > GJMessagePopup::onBlock @ 0x8c5874
// > SetTextPopup::onClose @ 0x8c59d4
// > FriendRequestPopup::onBlock @ 0x8c5c34
// > FriendRequestPopup::onBlock @ 0x8c5c60
// > FriendRequestPopup::onBlock @ 0x8c5c7c
// > GJOptionsLayer::onToggle @ 0x8c5e00
// > UIPOptionsLayer::init @ 0x8c6350
// > TOSPopup::init @ 0x8c6988
// > SelectFontLayer::init @ 0x8c7204
// > SelectFontLayer::init @ 0x8c7230
// > EditTriggersPopup::init @ 0x8c7690
// > EditTriggersPopup::init @ 0x8c76bc
// > SetupEnterTriggerPopup::init @ 0x8c7f54
// > SetupEnterTriggerPopup::init @ 0x8c7f78
// > SetupEnterTriggerPopup::init @ 0x8c7f9c
// > SetupEnterTriggerPopup::init @ 0x8c7fc0
// > GJOptionsLayer::countForPage @ 0x8c845c
// > GJOptionsLayer::incrementCountForPage @ 0x8c86ac
// > GJOptionsLayer::objectsForPage @ 0x8c889c
// > GJOptionsLayer::layerForPage @ 0x8c8aa0
// > GJOptionsLayer::onInfo @ 0x8c8c7c
// > GJOptionsLayer::onInfo @ 0x8c8ca8
// > GJOptionsLayer::goToPage @ 0x8c907c
// > GJOptionsLayer::goToPage @ 0x8c90c8
// > GJCommentListLayer::init @ 0x8c9da8
// > GJCommentListLayer::init @ 0x8c9dc4
// > UpdateAccountSettingsPopup::init @ 0x8ca8dc
// > UpdateAccountSettingsPopup::init @ 0x8ca8f8
// > UpdateAccountSettingsPopup::init @ 0x8ca920
// > UpdateAccountSettingsPopup::init @ 0x8ca944
// > UpdateAccountSettingsPopup::init @ 0x8ca968
// > UpdateAccountSettingsPopup::init @ 0x8ca98c
// > UpdateAccountSettingsPopup::init @ 0x8ca9b0
// > UpdateAccountSettingsPopup::init @ 0x8ca9d8
// > UpdateAccountSettingsPopup::create @ 0x8caed0
// > UpdateAccountSettingsPopup::create @ 0x8caef4
// > UpdateAccountSettingsPopup::create @ 0x8caf18
// > UpdateAccountSettingsPopup::create @ 0x8caf3c
// > UpdateAccountSettingsPopup::create @ 0x8caf8c
// > UpdateAccountSettingsPopup::create @ 0x8cafac
// > UpdateAccountSettingsPopup::create @ 0x8cafec
// > UploadActionPopup::init @ 0x8cb48c
// > UploadActionPopup::create @ 0x8cb684
// > FriendRequestPopup::onAccept @ 0x8cb7d0
// > FriendRequestPopup::onRemove @ 0x8cb90c
// > GJWriteMessagePopup::onSend @ 0x8cbcd4
// > GJWriteMessagePopup::onSend @ 0x8cbcfc
// > GJWriteMessagePopup::onSend @ 0x8cbd28
// > GJWriteMessagePopup::onSend @ 0x8cbd50
// > UploadActionPopup::showSuccessMessage @ 0x8cbec8
// > FriendRequestPopup::uploadActionFinished @ 0x8cc0cc
// > FriendRequestPopup::uploadActionFinished @ 0x8cc0f8
// > GJMessagePopup::uploadActionFinished @ 0x8cc310
// > GJMessagePopup::uploadActionFinished @ 0x8cc33c
// > GJWriteMessagePopup::uploadMessageFinished @ 0x8cc458
// > UploadActionPopup::showFailMessage @ 0x8cc5c4
// > FriendRequestPopup::uploadActionFailed @ 0x8cc6e0
// > GJMessagePopup::uploadActionFailed @ 0x8cc808
// > GJWriteMessagePopup::uploadMessageFailed @ 0x8cc918
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd2d8
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd2f4
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd310
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd32c
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd354
// > FriendRequestPopup::loadFromGJFriendRequest @ 0x8cd380
// > FriendRequestPopup::init @ 0x8cda3c
// > FriendRequestPopup::init @ 0x8cda68
// > FriendRequestPopup::blockUser @ 0x8cdcf4
// > GJMessagePopup::loadFromGJMessage @ 0x8ce33c
// > GJMessagePopup::loadFromGJMessage @ 0x8ce364
// > GJMessagePopup::loadFromGJMessage @ 0x8ce388
// > GJMessagePopup::init @ 0x8ced98
// > GJMessagePopup::init @ 0x8cedc0
// > GJMessagePopup::init @ 0x8cedf0
// > GJMessagePopup::blockUser @ 0x8cf0fc
// > GJMessagePopup::FLAlert_Clicked @ 0x8cf280
// > GJWriteMessagePopup::closeMessagePopup @ 0x8cf4cc
// > GJWriteMessagePopup::updateText @ 0x8cf950
// > GJWriteMessagePopup::updateText @ 0x8cf96c
// > GJWriteMessagePopup::updateText @ 0x8cf998
// > GJWriteMessagePopup::updateSubject @ 0x8cfa90
// > GJWriteMessagePopup::updateBody @ 0x8cfb80
// > GJWriteMessagePopup::init @ 0x8d0ac8
// > GJWriteMessagePopup::init @ 0x8d0ae4
// > GJWriteMessagePopup::init @ 0x8d0b0c
// > GJWriteMessagePopup::init @ 0x8d0b30
// > GJMessagePopup::onReply @ 0x8d0ff8
// > GJMessagePopup::onReply @ 0x8d1014
// > GJMessagePopup::onReply @ 0x8d1044
// > GJWriteMessagePopup::textChanged @ 0x8d123c
// > GJWriteMessagePopup::textChanged @ 0x8d1268
// > GJWriteMessagePopup::textChanged @ 0x8d1290
// > EditGameObjectPopup::init @ 0x8d1598
// > EditGameObjectPopup::init @ 0x8d15e0
// > EditGameObjectPopup::init @ 0x8d1608
// > SetIDPopup::updateTextInputLabel @ 0x8d1950
// > SetIDPopup::init @ 0x8d227c
// > SetIDPopup::create @ 0x8d2584
// > SetIDPopup::create @ 0x8d25a4
// > FindObjectPopup::init @ 0x8d278c
// > FindObjectPopup::init @ 0x8d27a8
// > SetColorIDPopup::init @ 0x8d2b24
// > SetColorIDPopup::init @ 0x8d2b4c
// > SetColorIDPopup::init @ 0x8d2b78
// > SetFolderPopup::init @ 0x8d310c
// > SetFolderPopup::init @ 0x8d3128
// > SetFolderPopup::create @ 0x8d3354
// > SetTextPopup::updateTextInputLabel @ 0x8d3468
// > SetTextPopup::init @ 0x8d3bd8
// > SetTextPopup::create @ 0x8d3f70
// > SetTextPopup::create @ 0x8d3f90
// > SetTextPopup::create @ 0x8d3fe4
// > SetTextPopup::create @ 0x8d4004
// > SetFolderPopup::onSetFolderName @ 0x8d4300
// > SetFolderPopup::onSetFolderName @ 0x8d431c
// > SetFolderPopup::onSetFolderName @ 0x8d4338
// > SetFolderPopup::onSetFolderName @ 0x8d4354
// > SetFolderPopup::onSetFolderName @ 0x8d4370
// > TextAlertPopup::create @ 0x8d48dc
// > TextAlertPopup::create @ 0x8d48fc
// > OptionsObject::create @ 0x8d4cfc
// > GameOptionsLayer::showPracticeMusicSyncUnlockInfo @ 0x8d5c8c
// > GameOptionsLayer::showPracticeMusicSyncUnlockInfo @ 0x8d5ca8
// > GameOptionsLayer::showPracticeMusicSyncUnlockInfo @ 0x8d5cc4
// > GameOptionsLayer::showPracticeMusicSyncUnlockInfo @ 0x8d5ce0
// > UIOptionsLayer::toggleUIGroup @ 0x8d62e8
// > UIOptionsLayer::init @ 0x8d7fb8
// > UISaveLoadLayer::onSave @ 0x8d87c8
// > UISaveLoadLayer::onSave @ 0x8d87f4
// > UISaveLoadLayer::onSave @ 0x8d8810
// > UISaveLoadLayer::onLoad @ 0x8d8ab8
// > UISaveLoadLayer::onLoad @ 0x8d8ae4
// > UISaveLoadLayer::onLoad @ 0x8d8b00
// > UISaveLoadLayer::init @ 0x8d92f8
// > UISaveLoadLayer::init @ 0x8d9324
// > UISaveLoadLayer::init @ 0x8d9350
// > URLViewLayer::create @ 0x8d9860
// > GJPromoPopup::create @ 0x8d9c94
// > GJDifficultySprite::getDifficultyFrame @ 0x8d9db8
// > GJDifficultySprite::init @ 0x8d9ea8
// > GJDifficultySprite::updateDifficultyFrame @ 0x8da114
// > GJDifficultySprite::updateFeatureState @ 0x8da460
// > GJDifficultySprite::updateFeatureState @ 0x8da47c
// > GJOptionsLayer::addToggleInternal @ 0x8db180
// > GJOptionsLayer::addToggleInternal @ 0x8db19c
// > GJOptionsLayer::addToggleInternal @ 0x8db1d4
// > GJOptionsLayer::addGVToggle @ 0x8db324
// > GameOptionsLayer::setupOptions @ 0x8dc3fc
// > GameOptionsLayer::setupOptions @ 0x8dc424
// > GJAccountSettingsLayer::closeAccInputNodes @ 0x8dc7c4
// > GJAccountSettingsLayer::onUpdate @ 0x8dd4a4
// > GJAccountSettingsLayer::onUpdate @ 0x8dd4c0
// > GJAccountSettingsLayer::onUpdate @ 0x8dd4dc
// > GJAccountSettingsLayer::onUpdate @ 0x8dd504
// > GJAccountSettingsLayer::onUpdate @ 0x8dd520
// > GJAccountSettingsLayer::onUpdate @ 0x8dd554
// > GJAccountSettingsLayer::onUpdate @ 0x8dd57c
// > GJAccountSettingsLayer::updateScoreValues @ 0x8de178
// > GJAccountSettingsLayer::init @ 0x8e02c0
// > GJAccountSettingsLayer::init @ 0x8e02e8
// > GJAccountSettingsLayer::init @ 0x8e0328
// > GJAccountSettingsLayer::init @ 0x8e0350
// > GJAccountSettingsLayer::init @ 0x8e0378
// > GJAccountSettingsLayer::init @ 0x8e03bc
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall sub_4DC698(void *p)
{
unsigned int *v1; // x3
int v2; // w2
if ( &pthread_create )
{
v1 = (unsigned int *)((char *)p + 16);
do
v2 = __ldaxr(v1);
while ( __stlxr(v2 - 1, v1) );
}
else
{
v2 = *((_DWORD *)p + 4);
*((_DWORD *)p + 4) = v2 - 1;
}
if ( v2 <= 0 )
operator delete(p);
}