//
// MessageThreadsPage::dMessageThreadsPage from 0x1400d2b40 to 0x1400d2cfb (443 bytes)
//
// 3 xrefs:
// > sub_140101B8C @ 0x140101b93
// > ??> @ 0x14072cf00
// > ??> @ 0x1409144ec
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:26:25 +0000
//
// Hidden C++ exception states: #wind=1
char *__fastcall MessageThreadsPage::dMessageThreadsPage(char *Block, char a2)
{
char *v4; // rdi
__int64 v5; // rax
void *v6; // rax
cocos2d::CCNotificationCenter *v7; // rax
cocos2d::CCNotificationCenter *v8; // rax
__int64 v9; // rax
cocos2d::CCObject *v10; // rcx
cocos2d::CCObject *v11; // rcx
*(_QWORD *)Block = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 40) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 41) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 42) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 43) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 44) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 51) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 54) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 68) = &MessageThreadsPage::`vftable';
v4 = Block + 664;
*((_QWORD *)Block + 83) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 84) = &MessageThreadsPage::`vftable';
*((_QWORD *)Block + 85) = &MessageThreadsPage::`vftable';
v5 = *(_QWORD *)&qword_14090BFB0;
if ( !*(_QWORD *)&qword_14090BFB0 )
{
v6 = operator new(0x690u);
*(_QWORD *)&qword_14090BFB0 = GameLevelManager::GameLevelManager(v6);
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)&qword_14090BFB0 + 72LL))(*(_QWORD *)&qword_14090BFB0);
v5 = *(_QWORD *)&qword_14090BFB0;
}
if ( *(char **)(v5 + 1392) == v4 )
*(_QWORD *)(v5 + 1392) = 0;
v7 = (cocos2d::CCNotificationCenter *)cocos2d::CCNotificationCenter::sharedNotificationCenter();
cocos2d::CCNotificationCenter::removeObserver(v7, (struct cocos2d::CCObject *)Block, "ThreadsChangedNotification");
v8 = (cocos2d::CCNotificationCenter *)cocos2d::CCNotificationCenter::sharedNotificationCenter();
cocos2d::CCNotificationCenter::removeObserver(
v8,
(struct cocos2d::CCObject *)Block,
"ThreadSelectionChangedNotification");
v9 = *((_QWORD *)Block + 98);
if ( v9 )
*(_QWORD *)(v9 + 600) = 0;
v10 = *((cocos2d::CCObject **)Block + 100);
if ( v10 )
cocos2d::CCObject::release(v10);
v11 = *((cocos2d::CCObject **)Block + 111);
if ( v11 )
cocos2d::CCObject::release(v11);
sub_14003D310((__int64)(Block + 896));
sub_14003D310((__int64)(Block + 808));
FLAlertLayer::dFLAlertLayer((__int64)Block);
if ( (a2 & 1) != 0 )
j_j_free(Block);
return Block;
}