// // CharacterColorPage::onPlayerColor from 0x69d21c to 0x69d3a4 (392 bytes) // // 0 xrefs: // // This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False! // // 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:56:20 +0000 // unsigned int __fastcall CharacterColorPage::onPlayerColor(CharacterColorPage *this, cocos2d::CCObject *a2) { int v4; // r8 int v5; // r5 unsigned int result; // r0 GameManager *active; // r0 GameManager *v8; // r1 GameManager *v9; // r0 GameManager *v10; // r0 int v11; // r0 int v12; // r3 GameManager *v13; // r0 int v14; // r0 int v15; // r8 int v16; // s15 int v17; // r0 int v18; // r8 int v19; // s15 int v20; // r0 int v21; // r8 int v22; // s15 int v23; // r0 const cocos2d::CCPoint *v24; // r5 const cocos2d::CCPoint *v25; // r10 int v26; // r8 void (__fastcall *v27)(int, _BYTE *); // r9 _BYTE v28[8]; // [sp+4h] [bp-14h] BYREF _BYTE v29[8]; // [sp+Ch] [bp-Ch] BYREF if ( *((_DWORD *)this + 130) ) v4 = 3; else v4 = 2; v5 = (*(int (__fastcall **)(cocos2d::CCObject *))(*(_DWORD *)a2 + 32))(a2); result = CharacterColorPage::checkColor(this, v5, v4); if ( result ) { active = (GameManager *)CharacterColorPage::activeColorForMode(this, *((_DWORD *)this + 130)); v8 = active; if ( active == (GameManager *)v5 ) { result = *((_DWORD *)this + 137); if ( result ) return (*(int (__fastcall **)(unsigned int, GameManager *, int))(*(_DWORD *)result + 4))(result, v8, v4); } else { v9 = (GameManager *)GameManager::sharedState(active); *((_BYTE *)v9 + 460) = 0; v10 = (GameManager *)GameManager::sharedState(v9); v11 = GameManager::colorForIdx(v10, v5); v12 = *((_DWORD *)this + 130); v13 = (GameManager *)BYTE2(v11); switch ( v12 ) { case 1: v17 = GameManager::sharedState(v13); *(_DWORD *)(v17 + 632) = v5; v18 = v17; v19 = (int)(float)(vcvts_n_f32_s32(rand(), 0x1Fu) * 1000.0); *(_DWORD *)(v18 + 628) = v19; *(_DWORD *)(v18 + 624) = v19 + v5; break; case 2: v20 = GameManager::sharedState(v13); *(_DWORD *)(v20 + 644) = v5; v21 = v20; v22 = (int)(float)(vcvts_n_f32_s32(rand(), 0x1Fu) * 1000.0); *(_DWORD *)(v21 + 640) = v22; *(_DWORD *)(v21 + 636) = v22 + v5; break; case 0: v14 = GameManager::sharedState(v13); *(_DWORD *)(v14 + 620) = v5; v15 = v14; v16 = (int)(float)(vcvts_n_f32_s32(rand(), 0x1Fu) * 1000.0); *(_DWORD *)(v15 + 616) = v16; *(_DWORD *)(v15 + 612) = v16 + v5; break; } v23 = cocos2d::CCArray::objectAtIndex(*((cocos2d::CCArray **)this + 136), *((_DWORD *)this + 130)); v24 = *((const cocos2d::CCPoint **)this + 111); v25 = *((const cocos2d::CCPoint **)this + 115); v26 = v23; v27 = *(void (__fastcall **)(int, _BYTE *))(*(_DWORD *)v23 + 92); (*(void (__fastcall **)(cocos2d::CCObject *))(*(_DWORD *)a2 + 96))(a2); cocos2d::CCNode::convertToWorldSpace((cocos2d::CCNode *)v28, v24); cocos2d::CCNode::convertToNodeSpace((cocos2d::CCNode *)v29, v25); v27(v26, v29); return CharacterColorPage::updateIconColors((cocos2d::CCArray **)this); } } return result; }