{"type": "func", "start": 5370775536, "end": 5370775789, "name": "GauntletSprite::toggleLockedSprite", "pseudocode": "// \n// GauntletSprite::toggleLockedSprite from 0x1401f87f0 to 0x1401f88ed (253 bytes)\n// \n// 3 xrefs:\n// > GauntletLayer::setupGauntlet @ 0x1401f716b\n// > GauntletLayer::unlockActiveItem @ 0x1401f7e6b\n// > <???> @ 0x1406cc948\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\n// Hidden C++ exception states: #wind=1\nvoid GauntletSprite::toggleLockedSprite(GauntletSprite *a1, bool a2)\n{\n  float v2; // xmm0_4\n  const char *v5; // rcx\n  struct cocos2d::CCSprite *v6; // rdi\n  cocos2d::CCSprite_vtbl *v7; // rbx\n  const cocos2d::CCSize *v8; // rax\n  const cocos2d::CCPoint *v9; // rax\n  _QWORD v10[4]; // [rsp+28h] [rbp-40h] BYREF\n\n  a1->removeAllChildren(a1);\n  if ( a2 )\n  {\n    GauntletSprite::addLockedSprite(a1);\n  }\n  else\n  {\n    GauntletNode::frameForType(v10, (unsigned int)a1->m_gauntletType);\n    v5 = (const char *)v10;\n    if ( v10[3] > 0xFu )\n      v5 = (const char *)v10[0];\n    v6 = cocos2d::CCSprite::createWithSpriteFrameName(v5);\n    a1->addChild_1(a1, v6);\n    v7 = v6->cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable;\n    a1->getContentSize(a1);\n    v8 = a1->getContentSize(a1);\n    cocos2d::CCPoint::CCPoint(v2, v8->width * 0.5);\n    v7->setPosition_0(v6, v9);\n    sub_14003A830((__int64)v10);\n  }\n}", "assembly": "; \n; GauntletSprite::toggleLockedSprite from 0x1401f87f0 to 0x1401f88ed (253 bytes)\n; \n; 3 xrefs:\n; > GauntletLayer::setupGauntlet @ 0x1401f716b\n; > GauntletLayer::unlockActiveItem @ 0x1401f7e6b\n; > <???> @ 0x1406cc948\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\nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x1401f87f0\nmov     [rsp+arg_10], rsi                                              ; +0x5, 0x1401f87f5\npush    rdi                                                            ; +0xa, 0x1401f87fa\nsub     rsp, 60h                                                       ; +0xb, 0x1401f87fb\nmovaps  [rsp+68h+var_18], xmm6                                         ; +0xf, 0x1401f87ff\nmov     rax, cs:__security_cookie                                      ; +0x14, 0x1401f8804\nxor     rax, rsp                                                       ; +0x1b, 0x1401f880b\nmov     [rsp+68h+var_20], rax                                          ; +0x1e, 0x1401f880e\nmovzx   ebx, dl                                                        ; +0x23, 0x1401f8813\nmov     rsi, rcx                                                       ; +0x26, 0x1401f8816\nmov     rax, [rcx]                                                     ; +0x29, 0x1401f8819\ncall    qword ptr [rax+228h]                                           ; +0x2c, 0x1401f881c\ntest    bl, bl                                                         ; +0x32, 0x1401f8822\njnz     loc_1401F88C0                                                  ; +0x34, 0x1401f8824\nmov     edx, [rsi+140h]                                                ; +0x3a, 0x1401f882a\nlea     rcx, [rsp+68h+var_40]                                          ; +0x40, 0x1401f8830\ncall    GauntletNode__frameForType                                     ; +0x45, 0x1401f8835\nnop                                                                    ; +0x4a, 0x1401f883a\nlea     rcx, [rsp+68h+var_40]                                          ; +0x4b, 0x1401f883b\ncmp     [rsp+68h+var_28], 0Fh                                          ; +0x50, 0x1401f8840\ncmova   rcx, [rsp+68h+var_40]                                          ; +0x56, 0x1401f8846\ncall    cs:?createWithSpriteFrameName@CCSprite@cocos2d@@SAPEAV12@PEBD@Z; cocos2d::CCSprite::createWithSpriteFrameName(char const *) ; +0x5c, 0x1401f884c\nmov     rdi, rax                                                       ; +0x62, 0x1401f8852\nmov     r8, [rsi]                                                      ; +0x65, 0x1401f8855\nmov     rdx, rax                                                       ; +0x68, 0x1401f8858\nmov     rcx, rsi                                                       ; +0x6b, 0x1401f885b\ncall    qword ptr [r8+1C0h]                                            ; +0x6e, 0x1401f885e\nmov     rbx, [rdi]                                                     ; +0x75, 0x1401f8865\nmov     rdx, [rsi]                                                     ; +0x78, 0x1401f8868\nmov     rcx, rsi                                                       ; +0x7b, 0x1401f886b\ncall    qword ptr [rdx+130h]                                           ; +0x7e, 0x1401f886e\nmovss   xmm6, dword ptr [rax+4]                                        ; +0x84, 0x1401f8874\nmov     rdx, [rsi]                                                     ; +0x89, 0x1401f8879\nmov     rcx, rsi                                                       ; +0x8c, 0x1401f887c\ncall    qword ptr [rdx+130h]                                           ; +0x8f, 0x1401f887f\nmulss   xmm6, cs:dword_140622B08                                       ; +0x95, 0x1401f8885\nmovss   xmm1, dword ptr [rax]                                          ; +0x9d, 0x1401f888d\nmulss   xmm1, cs:dword_140622B08                                       ; +0xa1, 0x1401f8891\nmovaps  xmm2, xmm6                                                     ; +0xa9, 0x1401f8899\nlea     rcx, [rsp+68h+var_48]                                          ; +0xac, 0x1401f889c\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0xb1, 0x1401f88a1\nmov     rdx, rax                                                       ; +0xb7, 0x1401f88a7\nmov     rcx, rdi                                                       ; +0xba, 0x1401f88aa\ncall    qword ptr [rbx+0B8h]                                           ; +0xbd, 0x1401f88ad\nnop                                                                    ; +0xc3, 0x1401f88b3\nlea     rcx, [rsp+68h+var_40]                                          ; +0xc4, 0x1401f88b4\ncall    sub_14003A830                                                  ; +0xc9, 0x1401f88b9\njmp     short loc_1401F88C8                                            ; +0xce, 0x1401f88be\nmov     rcx, rsi                                                       ; +0xd0, 0x1401f88c0\ncall    GauntletSprite__addLockedSprite                                ; +0xd3, 0x1401f88c3\nmov     rcx, [rsp+68h+var_20]                                          ; +0xd8, 0x1401f88c8\nxor     rcx, rsp; StackCookie                                          ; +0xdd, 0x1401f88cd\ncall    __security_check_cookie                                        ; +0xe0, 0x1401f88d0\nmov     rbx, [rsp+68h+arg_8]                                           ; +0xe5, 0x1401f88d5\nmov     rsi, [rsp+68h+arg_10]                                          ; +0xea, 0x1401f88da\nmovaps  xmm6, [rsp+68h+var_18]                                         ; +0xf2, 0x1401f88e2\nadd     rsp, 60h                                                       ; +0xf7, 0x1401f88e7\npop     rdi                                                            ; +0xfb, 0x1401f88eb\nretn                                                                   ; +0xfc, 0x1401f88ec", "xrefs": ["GauntletLayer::setupGauntlet @ 0x1401f716b", "GauntletLayer::unlockActiveItem @ 0x1401f7e6b", "<???> @ 0x1406cc948"], "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"}