{"type": "func", "start": 6362856, "end": 6363084, "name": "AnimatedShopKeeper::playReactAnimation", "pseudocode": "// \n// AnimatedShopKeeper::playReactAnimation from 0x6116e8 to 0x6117cc (228 bytes)\n// \n// 1 xrefs:\n// > GJShopLayer::ccTouchBegan @ 0x6129d8\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:54:52 +0000\n// \n\nint __fastcall AnimatedShopKeeper::playReactAnimation(int this)\n{\n  int v1; // r4\n  int v2; // r6\n  cocos2d::CCString *v3; // r0\n  const char *CString; // r6\n  size_t v5; // r0\n  FMODAudioEngine *v6; // r0\n  FMODAudioEngine *v7; // r8\n  int v8[3]; // [sp+8h] [bp-28h] BYREF\n  int v9[3]; // [sp+14h] [bp-1Ch] BYREF\n  int v10[3]; // [sp+20h] [bp-10h] BYREF\n\n  v1 = this;\n  if ( !*(_BYTE *)(this + 581) )\n  {\n    v2 = *(_DWORD *)(this + 588) + 1;\n    if ( v2 > 3 )\n      *(_DWORD *)(this + 588) = 1;\n    else\n      *(_DWORD *)(this + 588) = v2;\n    v3 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(\n                                (cocos2d::CCString *)\"grunt0%i.ogg\",\n                                *(const char **)(this + 588));\n    memset(v8, 0, sizeof(v8));\n    CString = (const char *)cocos2d::CCString::getCString(v3);\n    v5 = strlen(CString);\n    v6 = (FMODAudioEngine *)std::string::__init(v8, CString, v5);\n    v7 = (FMODAudioEngine *)FMODAudioEngine::sharedEngine(v6);\n    std::string::basic_string(v9, (int)v8);\n    FMODAudioEngine::playEffect(v7, (int)v9, 1065353216, 0, 1059481190);\n    std::string::~string((int)v9);\n    memset(v10, 0, sizeof(v10));\n    std::string::__init(v10, \"react01\", 7u);\n    CCAnimatedSprite::runAnimationForced(v1, (int)v10);\n    std::string::~string((int)v10);\n    *(_BYTE *)(v1 + 581) = 1;\n    ++*(_DWORD *)(v1 + 584);\n    return std::string::~string((int)v8);\n  }\n  return this;\n}", "assembly": "; \n; AnimatedShopKeeper::playReactAnimation from 0x6116e8 to 0x6117cc (228 bytes)\n; \n; 1 xrefs:\n; > GJShopLayer::ccTouchBegan @ 0x6129d8\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:54:52 +0000\n; \nLDR             R3, =(__stack_chk_guard_ptr - 0x6116F2)                ; +0x0, 0x6116e8\nPUSH.W          {R4-R8,LR}                                             ; +0x2, 0x6116ea\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x6116ee\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x6116f0\nSUB             SP, SP, #0x30                                          ; +0xa, 0x6116f2\nMOV             R4, R0                                                 ; +0xc, 0x6116f4\nLDR             R2, [R3]                                               ; +0xe, 0x6116f6\nMOV             R7, R3                                                 ; +0x10, 0x6116f8\nSTR             R2, [SP,#0x30+var_4]                                   ; +0x12, 0x6116fa\nLDRB.W          R2, [R0,#0x245]                                        ; +0x14, 0x6116fc\nCMP             R2, #0                                                 ; +0x18, 0x611700\nBNE             loc_6117BA                                             ; +0x1a, 0x611702\nLDR.W           R6, [R0,#0x24C]                                        ; +0x1c, 0x611704\nADD             R5, SP, #0x30+var_28                                   ; +0x20, 0x611708\nADDS            R6, #1                                                 ; +0x22, 0x61170a\nCMP             R6, #3                                                 ; +0x24, 0x61170c\nITEE LE                                                                ; +0x26, 0x61170e\nSTRLE.W         R6, [R0,#0x24C]                                        ; +0x28, 0x611710\nMOVGT           R3, #1                                                 ; +0x2c, 0x611714\nSTRGT.W         R3, [R0,#0x24C]                                        ; +0x2e, 0x611716\nLDR             R0, =(aGrunt0IOgg - 0x611724); \"grunt0%i.ogg\"          ; +0x32, 0x61171a\nLDR.W           R1, [R4,#0x24C]; char *                                ; +0x34, 0x61171c\nADD             R0, PC; \"grunt0%i.ogg\"                                 ; +0x38, 0x611720\nBL              _ZN7cocos2d8CCString16createWithFormatEPKcz; cocos2d::CCString::createWithFormat(char const*,...) ; +0x3a, 0x611722\nBL              _ZNK7cocos2d8CCString10getCStringEv; cocos2d::CCString::getCString(void) ; +0x3e, 0x611726\nMOVS            R3, #0                                                 ; +0x42, 0x61172a\nSTR             R3, [SP,#0x30+var_28]                                  ; +0x44, 0x61172c\nSTR             R3, [SP,#0x30+var_24]                                  ; +0x46, 0x61172e\nSTR             R3, [SP,#0x30+var_20]                                  ; +0x48, 0x611730\nMOV             R6, R0                                                 ; +0x4a, 0x611732\nBLX             strlen                                                 ; +0x4c, 0x611734\nMOV             R1, R6                                                 ; +0x50, 0x611738\nMOV             R2, R0                                                 ; +0x52, 0x61173a\nMOV             R0, R5                                                 ; +0x54, 0x61173c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcj; std::string::__init(char const*,uint) ; +0x56, 0x61173e\nBL              _ZN15FMODAudioEngine12sharedEngineEv; FMODAudioEngine::sharedEngine(void) ; +0x5a, 0x611742\nADD             R6, SP, #0x30+var_1C                                   ; +0x5e, 0x611746\nMOV             R8, R0                                                 ; +0x60, 0x611748\nMOV             R1, R5                                                 ; +0x62, 0x61174a\nMOV             R0, R6                                                 ; +0x64, 0x61174c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x66, 0x61174e\nLDR             R3, flt_6117CC                                         ; +0x6a, 0x611752\nMOV             R0, R8; int                                            ; +0x6c, 0x611754\nMOV             R1, R6; int                                            ; +0x6e, 0x611756\nMOV.W           R2, #0x3F800000; int                                   ; +0x70, 0x611758\nSTR             R3, [SP,#0x30+var_30]; float                           ; +0x74, 0x61175c\nMOVS            R3, #0; int                                            ; +0x76, 0x61175e\nBL              _ZN15FMODAudioEngine10playEffectENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEEfff; FMODAudioEngine::playEffect(std::string,float,float,float) ; +0x78, 0x611760\nMOV             R0, R6                                                 ; +0x7c, 0x611764\nADD             R6, SP, #0x30+var_10                                   ; +0x7e, 0x611766\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x80, 0x611768\nLDR             R1, =(aReact01 - 0x611776); \"react01\"                  ; +0x84, 0x61176c\nMOV             R0, R6                                                 ; +0x86, 0x61176e\nMOVS            R2, #7                                                 ; +0x88, 0x611770\nADD             R1, PC; \"react01\"                                      ; +0x8a, 0x611772\nMOVS            R3, #0                                                 ; +0x8c, 0x611774\nSTR             R3, [SP,#0x30+var_10]                                  ; +0x8e, 0x611776\nSTR             R3, [SP,#0x30+var_C]                                   ; +0x90, 0x611778\nSTR             R3, [SP,#0x30+var_8]                                   ; +0x92, 0x61177a\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE6__initEPKcj; std::string::__init(char const*,uint) ; +0x94, 0x61177c\nMOV             R0, R4                                                 ; +0x98, 0x611780\nMOV             R1, R6                                                 ; +0x9a, 0x611782\nBL              _ZN16CCAnimatedSprite18runAnimationForcedENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE; CCAnimatedSprite::runAnimationForced(std::string) ; +0x9c, 0x611784\nMOV             R0, R6                                                 ; +0xa0, 0x611788\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xa2, 0x61178a\nMOVS            R3, #1                                                 ; +0xa6, 0x61178e\nSTRB.W          R3, [R4,#0x245]                                        ; +0xa8, 0x611790\nMOV             R0, R5                                                 ; +0xac, 0x611794\nLDR.W           R3, [R4,#0x248]                                        ; +0xae, 0x611796\nADDS            R3, #1                                                 ; +0xb2, 0x61179a\nSTR.W           R3, [R4,#0x248]                                        ; +0xb4, 0x61179c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xb8, 0x6117a0\nB               loc_6117BA                                             ; +0xbc, 0x6117a4\nB               loc_6117A8                                             ; +0xbe, 0x6117a6\nMOV             R0, R6                                                 ; +0xc0, 0x6117a8\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xc2, 0x6117aa\nB               loc_6117B0                                             ; +0xc6, 0x6117ae\nMOV             R0, R5                                                 ; +0xc8, 0x6117b0\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xca, 0x6117b2\nBL              __cxa_end_cleanup                                      ; +0xce, 0x6117b6\nLDR             R2, [SP,#0x30+var_4]                                   ; +0xd2, 0x6117ba\nLDR             R3, [R7]                                               ; +0xd4, 0x6117bc\nCMP             R2, R3                                                 ; +0xd6, 0x6117be\nBEQ             loc_6117C6                                             ; +0xd8, 0x6117c0\nBLX             __stack_chk_fail                                       ; +0xda, 0x6117c2\nADD             SP, SP, #0x30 ; '0'                                    ; +0xde, 0x6117c6\nPOP.W           {R4-R8,PC}                                             ; +0xe0, 0x6117c8", "xrefs": ["GJShopLayer::ccTouchBegan @ 0x6129d8"], "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"}