{"type": "func", "start": 4930896, "end": 4931302, "name": "GJDifficultySprite::updateFeatureState", "pseudocode": "// \n// GJDifficultySprite::updateFeatureState from 0x4b3d50 to 0x4b3ee6 (406 bytes)\n// \n// 3 xrefs:\n// > GJRateLevelLayer::onFeature @ 0x45311c\n// > RateStarsLayer::onFeature @ 0x455722\n// > GJDifficultySprite::updateFeatureStateFromLevel @ 0x4b3f3a\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nvoid GJDifficultySprite::updateFeatureState(GJDifficultySprite *a1, GJFeatureState a2)\n{\n  GJDifficultySprite_vtbl *v3; // r3\n  GJFeatureState m_featureState; // r3\n  char *v5; // r1\n  cocos2d::CCSprite *v6; // r5\n  void (__fastcall *setPosition)(cocos2d::CCSprite *__hidden, const cocos2d::CCPoint *); // r7\n  float width; // s17\n  const cocos2d::CCSize *v9; // r0\n  cocos2d::CCParticleSystemQuad *v10; // r5\n  void (__fastcall *v11)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // r10\n  float v12; // s17\n  const cocos2d::CCSize *v13; // r0\n  int v14; // r4\n  cocos2d::CCSprite *v15; // [sp+4h] [bp-14h] BYREF\n  void *v16; // [sp+8h] [bp-10h] BYREF\n  cocos2d::CCPoint v17; // [sp+Ch] [bp-Ch] BYREF\n\n  if ( a2 == a1->m_featureState )\n    return;\n  v3 = a1->cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;\n  a1->m_featureState = a2;\n  ((void (*)(void))v3->removeAllChildren)();\n  if ( !a1->m_featureState )\n    return;\n  sub_776584((int)&v15, \"GJ_featuredCoin_001.png\");\n  m_featureState = a1->m_featureState;\n  switch ( m_featureState )\n  {\n    case Mythic:\n      v5 = \"GJ_epicCoin3_001.png\";\nLABEL_5:\n      sub_7753D4((int)&v15, v5);\n      break;\n    case Legendary:\n      v5 = \"GJ_epicCoin2_001.png\";\n      goto LABEL_5;\n    case Epic:\n      v5 = \"GJ_epicCoin_001.png\";\n      goto LABEL_5;\n  }\n  v6 = cocos2d::CCSprite::createWithSpriteFrameName((const char *)v15);\n  a1->addChild_0(a1, v6, -2);\n  setPosition = v6->setPosition;\n  width = a1->getContentSize(a1)->width;\n  v9 = a1->getContentSize(a1);\n  cocos2d::CCPoint::CCPoint(&v17, width * 0.5, v9->height * 0.5);\n  setPosition(v6, &v17);\n  if ( a1->m_featureState == Mythic )\n  {\n    sub_776584(\n      (int)&v16,\n      \"30a-1a1.3a0.2a20a90a0a10a5a20a20a0a0a8a0a0a0a4a1a0a0a0a0a1a0a1a0a1a0a1a1a0a0a0a0a0.784314a0a1a0a1a0a0.27a0a0.27a0a\"\n      \"0a0a0a0a0a0a0a2a1a0a0a0a0a0a0a0.25a0a0a0a0a0a0a0a0a0a0a0\");\n    v10 = GameToolbox::particleFromString(&v16, nullptr, 0);\n    a1->addChild_0(a1, v10, -1);\n    ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, int))v10->setScale)(v10, 1063675494);\n    cocos2d::CCParticleSystem::resetSystem(v10);\n    v11 = v10->setPosition;\n    v12 = a1->getContentSize(a1)->width;\n    v13 = a1->getContentSize(a1);\n    cocos2d::CCPoint::CCPoint(&v17, v12 * 0.5, v13->height * 0.5);\n    v11(v10, &v17);\n    v14 = 5;\n    do\n    {\n      ((void (__fastcall *)(cocos2d::CCParticleSystemQuad *, int))v10->update)(v10, 1041865114);\n      --v14;\n    }\n    while ( v14 );\n    sub_774008(&v16);\n  }\n  sub_774008(&v15);\n}", "assembly": "; \n; GJDifficultySprite::updateFeatureState from 0x4b3d50 to 0x4b3ee6 (406 bytes)\n; \n; 3 xrefs:\n; > GJRateLevelLayer::onFeature @ 0x45311c\n; > RateStarsLayer::onFeature @ 0x455722\n; > GJDifficultySprite::updateFeatureStateFromLevel @ 0x4b3f3a\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nLDR             R3, =(__stack_chk_guard_ptr - 0x4B3D5A)                ; +0x0, 0x4b3d50\nPUSH.W          {R4-R10,LR}                                            ; +0x2, 0x4b3d52\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x4b3d56\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x4b3d58\nVPUSH           {D8}                                                   ; +0xa, 0x4b3d5a\nMOV             R4, R0                                                 ; +0xe, 0x4b3d5e\nLDR             R2, [R3]                                               ; +0x10, 0x4b3d60\nMOV             R8, R3                                                 ; +0x12, 0x4b3d62\nSUB             SP, SP, #0x18                                          ; +0x14, 0x4b3d64\nSTR             R2, [SP,#0x18+var_4]                                   ; +0x16, 0x4b3d66\nLDR.W           R2, [R0,#0x1FC]                                        ; +0x18, 0x4b3d68\nCMP             R1, R2                                                 ; +0x1c, 0x4b3d6c\nBEQ.W           loc_4B3ECE                                             ; +0x1e, 0x4b3d6e\nLDR             R3, [R0]                                               ; +0x22, 0x4b3d72\nSTR.W           R1, [R0,#0x1FC]                                        ; +0x24, 0x4b3d74\nLDR.W           R3, [R3,#0x118]                                        ; +0x28, 0x4b3d78\nBLX             R3                                                     ; +0x2c, 0x4b3d7c\nLDR.W           R3, [R4,#0x1FC]                                        ; +0x2e, 0x4b3d7e\nCMP             R3, #0                                                 ; +0x32, 0x4b3d82\nBEQ.W           loc_4B3ECE                                             ; +0x34, 0x4b3d84\nADD.W           R9, SP, #0x18+var_14                                   ; +0x38, 0x4b3d88\nADD             R6, SP, #0x18+var_C                                    ; +0x3c, 0x4b3d8c\nLDR             R1, =(aGjFeaturedcoin - 0x4B3D98); \"GJ_featuredCoin_001.png\" ; +0x3e, 0x4b3d8e\nMOV             R0, R9; int                                            ; +0x40, 0x4b3d90\nMOV             R2, R6                                                 ; +0x42, 0x4b3d92\nADD             R1, PC; \"GJ_featuredCoin_001.png\"                      ; +0x44, 0x4b3d94\nBL              sub_776584                                             ; +0x46, 0x4b3d96\nLDR.W           R3, [R4,#0x1FC]                                        ; +0x4a, 0x4b3d9a\nCMP             R3, #4                                                 ; +0x4e, 0x4b3d9e\nBNE             loc_4B3DC6                                             ; +0x50, 0x4b3da0\nLDR             R1, =(aGjEpiccoin3001 - 0x4B3DAA); \"GJ_epicCoin3_001.png\" ; +0x52, 0x4b3da2\nMOV             R0, R9; int                                            ; +0x54, 0x4b3da4\nADD             R1, PC; \"GJ_epicCoin3_001.png\"                         ; +0x56, 0x4b3da6\nBL              sub_7753D4                                             ; +0x58, 0x4b3da8\nLDR             R0, [SP,#0x18+var_14]; this                            ; +0x5c, 0x4b3dac\nBL              _ZN7cocos2d8CCSprite25createWithSpriteFrameNameEPKc; cocos2d::CCSprite::createWithSpriteFrameName(char const*) ; +0x5e, 0x4b3dae\nLDR             R3, [R4]                                               ; +0x62, 0x4b3db2\nMOV             R5, R0                                                 ; +0x64, 0x4b3db4\nMOV             R1, R5                                                 ; +0x66, 0x4b3db6\nMOV             R0, R4                                                 ; +0x68, 0x4b3db8\nMOV             R2, #0xFFFFFFFE                                        ; +0x6a, 0x4b3dba\nLDR.W           R3, [R3,#0xE0]                                         ; +0x6e, 0x4b3dbe\nBLX             R3                                                     ; +0x72, 0x4b3dc2\nB               loc_4B3DDE                                             ; +0x74, 0x4b3dc4\nCMP             R3, #3                                                 ; +0x76, 0x4b3dc6\nBNE             loc_4B3DD2                                             ; +0x78, 0x4b3dc8\nLDR             R1, =(aGjEpiccoin2001 - 0x4B3DD2); \"GJ_epicCoin2_001.png\" ; +0x7a, 0x4b3dca\nMOV             R0, R9                                                 ; +0x7c, 0x4b3dcc\nADD             R1, PC; \"GJ_epicCoin2_001.png\"                         ; +0x7e, 0x4b3dce\nB               loc_4B3DA8                                             ; +0x80, 0x4b3dd0\nCMP             R3, #2                                                 ; +0x82, 0x4b3dd2\nBNE             loc_4B3DAC                                             ; +0x84, 0x4b3dd4\nLDR             R1, =(aGjEpiccoin001P - 0x4B3DDE); \"GJ_epicCoin_001.png\" ; +0x86, 0x4b3dd6\nMOV             R0, R9                                                 ; +0x88, 0x4b3dd8\nADD             R1, PC; \"GJ_epicCoin_001.png\"                          ; +0x8a, 0x4b3dda\nB               loc_4B3DA8                                             ; +0x8c, 0x4b3ddc\nLDR             R3, [R5]                                               ; +0x8e, 0x4b3dde\nMOV             R0, R4                                                 ; +0x90, 0x4b3de0\nLDR             R7, [R3,#0x5C]                                         ; +0x92, 0x4b3de2\nLDR             R3, [R4]                                               ; +0x94, 0x4b3de4\nLDR.W           R3, [R3,#0x9C]                                         ; +0x96, 0x4b3de6\nBLX             R3                                                     ; +0x9a, 0x4b3dea\nVMOV.F32        S16, #0.5                                              ; +0x9c, 0x4b3dec\nLDR             R3, [R4]                                               ; +0xa0, 0x4b3df0\nVLDR            S17, [R0]                                              ; +0xa2, 0x4b3df2\nMOV             R0, R4                                                 ; +0xa6, 0x4b3df6\nLDR.W           R3, [R3,#0x9C]                                         ; +0xa8, 0x4b3df8\nVMUL.F32        S17, S17, S16                                          ; +0xac, 0x4b3dfc\nBLX             R3                                                     ; +0xb0, 0x4b3e00\nVLDR            S15, [R0,#4]                                           ; +0xb2, 0x4b3e02\nMOV             R0, R6; this                                           ; +0xb6, 0x4b3e06\nVMOV            R1, S17; float                                         ; +0xb8, 0x4b3e08\nVMUL.F32        S15, S15, S16                                          ; +0xbc, 0x4b3e0c\nVMOV            R2, S15; float                                         ; +0xc0, 0x4b3e10\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0xc4, 0x4b3e14\nMOV             R0, R5                                                 ; +0xc8, 0x4b3e18\nMOV             R1, R6                                                 ; +0xca, 0x4b3e1a\nBLX             R7                                                     ; +0xcc, 0x4b3e1c\nLDR.W           R3, [R4,#0x1FC]                                        ; +0xce, 0x4b3e1e\nCMP             R3, #4                                                 ; +0xd2, 0x4b3e22\nBNE             loc_4B3EB4                                             ; +0xd4, 0x4b3e24\nADD             R7, SP, #0x18+var_10                                   ; +0xd6, 0x4b3e26\nLDR             R1, =(a30a1a13a02a20a - 0x4B3E32); \"30a-1a1.3a0.2a20a90a0a10a5a20a20a0a0a8a\"... ; +0xd8, 0x4b3e28\nMOV             R2, R6                                                 ; +0xda, 0x4b3e2a\nMOV             R0, R7; int                                            ; +0xdc, 0x4b3e2c\nADD             R1, PC; \"30a-1a1.3a0.2a20a90a0a10a5a20a20a0a0a8a\"...   ; +0xde, 0x4b3e2e\nBL              sub_776584                                             ; +0xe0, 0x4b3e30\nMOVS            R1, #0                                                 ; +0xe4, 0x4b3e34\nMOV             R0, R7                                                 ; +0xe6, 0x4b3e36\nMOV             R2, R1                                                 ; +0xe8, 0x4b3e38\nBL              _ZN11GameToolbox18particleFromStringERKSsPN7cocos2d20CCParticleSystemQuadEb; GameToolbox::particleFromString(std::string const&,cocos2d::CCParticleSystemQuad *,bool) ; +0xea, 0x4b3e3a\nLDR             R3, [R4]                                               ; +0xee, 0x4b3e3e\nMOV             R5, R0                                                 ; +0xf0, 0x4b3e40\nMOV             R1, R5                                                 ; +0xf2, 0x4b3e42\nMOV             R0, R4                                                 ; +0xf4, 0x4b3e44\nMOV.W           R2, #0xFFFFFFFF                                        ; +0xf6, 0x4b3e46\nLDR.W           R3, [R3,#0xE0]                                         ; +0xfa, 0x4b3e4a\nBLX             R3                                                     ; +0xfe, 0x4b3e4e\nLDR             R3, [R5]                                               ; +0x100, 0x4b3e50\nMOV             R0, R5                                                 ; +0x102, 0x4b3e52\nLDR             R1, =0x3F666666                                        ; +0x104, 0x4b3e54\nLDR             R3, [R3,#0x50]                                         ; +0x106, 0x4b3e56\nBLX             R3                                                     ; +0x108, 0x4b3e58\nMOV             R0, R5; this                                           ; +0x10a, 0x4b3e5a\nBL              _ZN7cocos2d16CCParticleSystem11resetSystemEv; cocos2d::CCParticleSystem::resetSystem(void) ; +0x10c, 0x4b3e5c\nLDR             R3, [R5]                                               ; +0x110, 0x4b3e60\nMOV             R0, R4                                                 ; +0x112, 0x4b3e62\nLDR.W           R10, [R3,#0x5C]                                        ; +0x114, 0x4b3e64\nLDR             R3, [R4]                                               ; +0x118, 0x4b3e68\nLDR.W           R3, [R3,#0x9C]                                         ; +0x11a, 0x4b3e6a\nBLX             R3                                                     ; +0x11e, 0x4b3e6e\nVLDR            S17, [R0]                                              ; +0x120, 0x4b3e70\nMOV             R0, R4                                                 ; +0x124, 0x4b3e74\nLDR             R3, [R4]                                               ; +0x126, 0x4b3e76\nLDR.W           R3, [R3,#0x9C]                                         ; +0x128, 0x4b3e78\nVMUL.F32        S17, S17, S16                                          ; +0x12c, 0x4b3e7c\nBLX             R3                                                     ; +0x130, 0x4b3e80\nVLDR            S15, [R0,#4]                                           ; +0x132, 0x4b3e82\nMOV             R0, R6; this                                           ; +0x136, 0x4b3e86\nVMOV            R1, S17; float                                         ; +0x138, 0x4b3e88\nVMUL.F32        S15, S15, S16                                          ; +0x13c, 0x4b3e8c\nVMOV            R2, S15; float                                         ; +0x140, 0x4b3e90\nBL              _ZN7cocos2d7CCPointC1Eff; cocos2d::CCPoint::CCPoint(float,float) ; +0x144, 0x4b3e94\nMOV             R0, R5                                                 ; +0x148, 0x4b3e98\nMOV             R1, R6                                                 ; +0x14a, 0x4b3e9a\nBLX             R10                                                    ; +0x14c, 0x4b3e9c\nMOVS            R4, #5                                                 ; +0x14e, 0x4b3e9e\nLDR             R3, [R5]                                               ; +0x150, 0x4b3ea0\nMOV             R0, R5                                                 ; +0x152, 0x4b3ea2\nLDR             R1, =0x3E19999A                                        ; +0x154, 0x4b3ea4\nLDR             R3, [R3,#0x14]                                         ; +0x156, 0x4b3ea6\nBLX             R3                                                     ; +0x158, 0x4b3ea8\nSUBS            R4, #1                                                 ; +0x15a, 0x4b3eaa\nBNE             loc_4B3EA0                                             ; +0x15c, 0x4b3eac\nMOV             R0, R7                                                 ; +0x15e, 0x4b3eae\nBL              sub_774008                                             ; +0x160, 0x4b3eb0\nMOV             R0, R9                                                 ; +0x164, 0x4b3eb4\nBL              sub_774008                                             ; +0x166, 0x4b3eb6\nB               loc_4B3ECE                                             ; +0x16a, 0x4b3eba\nMOV             R0, R7                                                 ; +0x16c, 0x4b3ebc\nBL              sub_774008                                             ; +0x16e, 0x4b3ebe\nB               loc_4B3EC4                                             ; +0x172, 0x4b3ec2\nMOV             R0, R9                                                 ; +0x174, 0x4b3ec4\nBL              sub_774008                                             ; +0x176, 0x4b3ec6\nBL              __cxa_end_cleanup                                      ; +0x17a, 0x4b3eca\nLDR             R2, [SP,#0x18+var_4]                                   ; +0x17e, 0x4b3ece\nLDR.W           R3, [R8]                                               ; +0x180, 0x4b3ed0\nCMP             R2, R3                                                 ; +0x184, 0x4b3ed4\nBEQ             loc_4B3EDC                                             ; +0x186, 0x4b3ed6\nBLX             __stack_chk_fail                                       ; +0x188, 0x4b3ed8\nADD             SP, SP, #0x18                                          ; +0x18c, 0x4b3edc\nVPOP            {D8}                                                   ; +0x18e, 0x4b3ede\nPOP.W           {R4-R10,PC}                                            ; +0x192, 0x4b3ee2", "xrefs": ["GJRateLevelLayer::onFeature @ 0x45311c", "RateStarsLayer::onFeature @ 0x455722", "GJDifficultySprite::updateFeatureStateFromLevel @ 0x4b3f3a"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}