{"type": "func", "start": 5162184, "end": 5162396, "name": "AnimatedGameObject::updateObjectAnimation", "pseudocode": "// \n// AnimatedGameObject::updateObjectAnimation from 0x4ec4c8 to 0x4ec59c (212 bytes)\n// \n// 3 xrefs:\n// > LevelEditorLayer::updatePreviewAnim @ 0x462600\n// > AnimatedGameObject::activateObject @ 0x4ec5ba\n// > AnimatedGameObject::resetObject @ 0x4ec5f6\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:51:09 +0000\n// \n\ncocos2d::CCNode *__fastcall AnimatedGameObject::updateObjectAnimation(AnimatedGameObject *this)\n{\n  cocos2d::CCNode *result; // r0\n  int v3; // r1\n  int v4; // r3\n  int v5; // r7\n  int v6; // r3\n  char *v7; // r1\n  int v8; // r7\n  SpriteAnimationManager *v9; // r4\n  unsigned int v10; // r0\n  int v11[3]; // [sp+0h] [bp-14h] BYREF\n\n  result = SpriteAnimationManager::stopAnimations(*(SpriteAnimationManager **)(*((_DWORD *)this + 319) + 532));\n  if ( *((_BYTE *)this + 657) )\n  {\n    if ( !*((_BYTE *)this + 549)\n      || (result = (cocos2d::CCNode *)GameManager::sharedState(result), *(_BYTE *)(*((_DWORD *)result + 102) + 11705)) )\n    {\n      v3 = *((_DWORD *)this + 319);\n      if ( *((_BYTE *)this + 1289) )\n      {\n        v4 = *((unsigned __int8 *)this + 1292);\n        v5 = *(_DWORD *)(v3 + 532);\n        if ( (v4 & 1) != 0 )\n          v6 = *((_DWORD *)this + 324);\n        else\n          v6 = v4 >> 1;\n        if ( v6 )\n          v7 = (char *)this + 1292;\n        else\n          v7 = (char *)(v3 + 552);\n        std::string::basic_string(v11, (int)v7);\n        SpriteAnimationManager::runAnimation(v5, (unsigned __int8 *)v11);\n        return (cocos2d::CCNode *)std::string::~string((int)v11);\n      }\n      else\n      {\n        v8 = *(_DWORD *)(v3 + 532);\n        std::string::basic_string(v11, v3 + 552);\n        SpriteAnimationManager::runAnimation(v8, (unsigned __int8 *)v11);\n        std::string::~string((int)v11);\n        v9 = *(SpriteAnimationManager **)(*((_DWORD *)this + 319) + 532);\n        v10 = rand();\n        return (cocos2d::CCNode *)SpriteAnimationManager::offsetCurrentAnimation(v9, vcvts_n_f32_s32(v10, 0x1Fu));\n      }\n    }\n  }\n  return result;\n}", "assembly": "; \n; AnimatedGameObject::updateObjectAnimation from 0x4ec4c8 to 0x4ec59c (212 bytes)\n; \n; 3 xrefs:\n; > LevelEditorLayer::updatePreviewAnim @ 0x462600\n; > AnimatedGameObject::activateObject @ 0x4ec5ba\n; > AnimatedGameObject::resetObject @ 0x4ec5f6\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:51:09 +0000\n; \nPUSH            {R4-R7,LR}                                             ; +0x0, 0x4ec4c8\nSUB             SP, SP, #0x14                                          ; +0x2, 0x4ec4ca\nLDR             R6, =(__stack_chk_guard_ptr - 0x4EC4D4)                ; +0x4, 0x4ec4cc\nMOV             R4, R0                                                 ; +0x6, 0x4ec4ce\nADD             R6, PC; __stack_chk_guard_ptr                          ; +0x8, 0x4ec4d0\nLDR             R6, [R6]; __stack_chk_guard                            ; +0xa, 0x4ec4d2\nLDR             R3, [R6]                                               ; +0xc, 0x4ec4d4\nSTR             R3, [SP,#0x14+var_8]                                   ; +0xe, 0x4ec4d6\nLDR.W           R3, [R0,#0x4FC]                                        ; +0x10, 0x4ec4d8\nLDR.W           R0, [R3,#0x214]; this                                  ; +0x14, 0x4ec4dc\nBL              _ZN22SpriteAnimationManager14stopAnimationsEv; SpriteAnimationManager::stopAnimations(void) ; +0x18, 0x4ec4e0\nLDRB.W          R3, [R4,#0x291]                                        ; +0x1c, 0x4ec4e4\nCMP             R3, #0                                                 ; +0x20, 0x4ec4e8\nBEQ             loc_4EC58C                                             ; +0x22, 0x4ec4ea\nLDRB.W          R3, [R4,#0x225]                                        ; +0x24, 0x4ec4ec\nCBZ             R3, loc_4EC504                                         ; +0x28, 0x4ec4f0\nBL              _ZN11GameManager11sharedStateEv; GameManager::sharedState(void) ; +0x2a, 0x4ec4f2\nMOVW            R3, #0x2DB9                                            ; +0x2e, 0x4ec4f6\nLDR.W           R2, [R0,#0x198]                                        ; +0x32, 0x4ec4fa\nLDRB            R3, [R2,R3]                                            ; +0x36, 0x4ec4fe\nCMP             R3, #0                                                 ; +0x38, 0x4ec500\nBEQ             loc_4EC58C                                             ; +0x3a, 0x4ec502\nLDRB.W          R3, [R4,#0x509]                                        ; +0x3c, 0x4ec504\nMOV             R5, SP                                                 ; +0x40, 0x4ec508\nLDR.W           R1, [R4,#0x4FC]                                        ; +0x42, 0x4ec50a\nCBZ             R3, loc_4EC544                                         ; +0x46, 0x4ec50e\nLDRB.W          R3, [R4,#0x50C]                                        ; +0x48, 0x4ec510\nMOV             R0, R5                                                 ; +0x4c, 0x4ec514\nLDR.W           R7, [R1,#0x214]                                        ; +0x4e, 0x4ec516\nLSLS            R2, R3, #0x1F                                          ; +0x52, 0x4ec51a\nITE PL                                                                 ; +0x54, 0x4ec51c\nASRPL           R3, R3, #1                                             ; +0x56, 0x4ec51e\nLDRMI.W         R3, [R4,#0x510]                                        ; +0x58, 0x4ec520\nCBNZ            R3, loc_4EC52C                                         ; +0x5c, 0x4ec524\nADD.W           R1, R1, #0x228                                         ; +0x5e, 0x4ec526\nB               loc_4EC530                                             ; +0x62, 0x4ec52a\nADDW            R1, R4, #0x50C                                         ; +0x64, 0x4ec52c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x68, 0x4ec530\nMOV             R0, R7                                                 ; +0x6c, 0x4ec534\nMOV             R1, R5                                                 ; +0x6e, 0x4ec536\nBL              _ZN22SpriteAnimationManager12runAnimationENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE; SpriteAnimationManager::runAnimation(std::string) ; +0x70, 0x4ec538\nMOV             R0, R5                                                 ; +0x74, 0x4ec53c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x76, 0x4ec53e\nB               loc_4EC58C                                             ; +0x7a, 0x4ec542\nLDR.W           R7, [R1,#0x214]                                        ; +0x7c, 0x4ec544\nMOV             R0, R5                                                 ; +0x80, 0x4ec548\nADD.W           R1, R1, #0x228                                         ; +0x82, 0x4ec54a\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x86, 0x4ec54e\nMOV             R1, R5                                                 ; +0x8a, 0x4ec552\nMOV             R0, R7                                                 ; +0x8c, 0x4ec554\nBL              _ZN22SpriteAnimationManager12runAnimationENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE; SpriteAnimationManager::runAnimation(std::string) ; +0x8e, 0x4ec556\nMOV             R0, R5                                                 ; +0x92, 0x4ec55a\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x94, 0x4ec55c\nLDR.W           R3, [R4,#0x4FC]                                        ; +0x98, 0x4ec560\nLDR.W           R4, [R3,#0x214]                                        ; +0x9c, 0x4ec564\nBLX             rand                                                   ; +0xa0, 0x4ec568\nVMOV            S15, R0                                                ; +0xa4, 0x4ec56c\nMOV             R0, R4; this                                           ; +0xa8, 0x4ec570\nVCVT.F32.S32    S15, S15, #0x1F                                        ; +0xaa, 0x4ec572\nVMOV            R1, S15; float                                         ; +0xae, 0x4ec576\nBL              _ZN22SpriteAnimationManager22offsetCurrentAnimationEf; SpriteAnimationManager::offsetCurrentAnimation(float) ; +0xb2, 0x4ec57a\nB               loc_4EC58C                                             ; +0xb6, 0x4ec57e\nB               loc_4EC582                                             ; +0xb8, 0x4ec580\nMOV             R0, R5                                                 ; +0xba, 0x4ec582\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xbc, 0x4ec584\nBL              __cxa_end_cleanup                                      ; +0xc0, 0x4ec588\nLDR             R2, [SP,#0x14+var_8]                                   ; +0xc4, 0x4ec58c\nLDR             R3, [R6]                                               ; +0xc6, 0x4ec58e\nCMP             R2, R3                                                 ; +0xc8, 0x4ec590\nBEQ             loc_4EC598                                             ; +0xca, 0x4ec592\nBLX             __stack_chk_fail                                       ; +0xcc, 0x4ec594\nADD             SP, SP, #0x14                                          ; +0xd0, 0x4ec598\nPOP             {R4-R7,PC}                                             ; +0xd2, 0x4ec59a", "xrefs": ["LevelEditorLayer::updatePreviewAnim @ 0x462600", "AnimatedGameObject::activateObject @ 0x4ec5ba", "AnimatedGameObject::resetObject @ 0x4ec5f6"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}