{"type": "func", "start": 3174684, "end": 3174804, "name": "CCSpriteGrayscale::create", "pseudocode": "// \n// CCSpriteGrayscale::create from 0x30711c to 0x307194 (120 bytes)\n// \n// 0 xrefs:\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\nCCSpriteWithHue *__fastcall CCSpriteGrayscale::create(const char **a1)\n{\n  CCSpriteWithHue *v2; // r0\n  CCSpriteWithHue *v3; // r4\n  const char *v4; // r1\n\n  v2 = (CCSpriteWithHue *)operator new(0x23Cu, (const std::nothrow_t *)&std::nothrow);\n  v3 = v2;\n  if ( !v2 )\n    return v3;\n  memset(v2, 0, sizeof(CCSpriteWithHue));\n  CCSpriteWithHue::CCSpriteWithHue(v3);\n  v4 = *a1;\n  v3->cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable = (CCSpriteWithHue_vtbl *)&off_A43940;\n  v3->cocos2d::CCSprite::cocos2d::CCNodeRGBA::cocos2d::CCRGBAProtocol::__vftable = (cocos2d::CCRGBAProtocol_vtbl *)&off_A43BB8;\n  v3->cocos2d::CCSprite::cocos2d::CCTextureProtocol::cocos2d::CCBlendProtocol::__vftable = (cocos2d::CCTextureProtocol_vtbl *)&off_A43BF8;\n  if ( cocos2d::CCSprite::initWithFile(v3, v4) )\n  {\n    cocos2d::CCObject::autorelease(v3);\n    return v3;\n  }\n  v3->~CCSpriteWithHue_0(v3);\n  return nullptr;\n}", "assembly": "; \n; CCSpriteGrayscale::create from 0x30711c to 0x307194 (120 bytes)\n; \n; 0 xrefs:\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\nPUSH            {R3-R7,LR}                                             ; +0x0, 0x30711c\nMOV             R7, R0                                                 ; +0x2, 0x30711e\nLDR             R5, =(_ZSt7nothrow_ptr - 0x30712C)                     ; +0x4, 0x307120\nMOV             R6, R1                                                 ; +0x6, 0x307122\nMOV.W           R0, #0x23C; unsigned int                               ; +0x8, 0x307124\nADD             R5, PC; _ZSt7nothrow_ptr                               ; +0xc, 0x307128\nLDR             R5, [R5]; std::nothrow ...                             ; +0xe, 0x30712a\nMOV             R1, R5; std::nothrow_t *                               ; +0x10, 0x30712c\nBL              _ZnwjRKSt9nothrow_t; operator new(uint,std::nothrow_t const&) ; +0x12, 0x30712e\nMOV             R4, R0                                                 ; +0x16, 0x307132\nCBZ             R0, loc_307184                                         ; +0x18, 0x307134\nMOVS            R1, #0; int                                            ; +0x1a, 0x307136\nMOV.W           R2, #0x23C; size_t                                     ; +0x1c, 0x307138\nBLX             memset                                                 ; +0x20, 0x30713c\nMOV             R0, R4; this                                           ; +0x24, 0x307140\nBL              _ZN15CCSpriteWithHueC2Ev; CCSpriteWithHue::CCSpriteWithHue(void) ; +0x26, 0x307142\nLDR             R3, =(_ZTV17CCSpriteGrayscale_ptr - 0x307150)          ; +0x2a, 0x307146\nMOV             R0, R4; this                                           ; +0x2c, 0x307148\nLDR             R1, [R7]; char *                                       ; +0x2e, 0x30714a\nADD             R3, PC; _ZTV17CCSpriteGrayscale_ptr                    ; +0x30, 0x30714c\nLDR             R3, [R3]; `vtable for'CCSpriteGrayscale ...            ; +0x32, 0x30714e\nADD.W           R2, R3, #8                                             ; +0x34, 0x307150\nSTR             R2, [R4]                                               ; +0x38, 0x307154\nADD.W           R2, R3, #0x280                                         ; +0x3a, 0x307156\nADD.W           R3, R3, #0x2C0                                         ; +0x3e, 0x30715a\nSTR.W           R2, [R4,#0x108]                                        ; +0x42, 0x30715e\nMOV             R2, R6; cocos2d::CCRect *                              ; +0x46, 0x307162\nSTR.W           R3, [R4,#0x118]                                        ; +0x48, 0x307164\nBL              _ZN7cocos2d8CCSprite12initWithFileEPKcRKNS_6CCRectE; cocos2d::CCSprite::initWithFile(char const*,cocos2d::CCRect const&) ; +0x4c, 0x307168\nMOV             R5, R0                                                 ; +0x50, 0x30716c\nCBZ             R0, loc_307188                                         ; +0x52, 0x30716e\nMOV             R0, R4; this                                           ; +0x54, 0x307170\nBL              _ZN7cocos2d8CCObject11autoreleaseEv; cocos2d::CCObject::autorelease(void) ; +0x56, 0x307172\nB               loc_307184                                             ; +0x5a, 0x307176\nMOV             R0, R4; p                                              ; +0x5c, 0x307178\nMOV             R1, R5; std::nothrow_t *                               ; +0x5e, 0x30717a\nBL              _ZdlPvRKSt9nothrow_t; operator delete(void *,std::nothrow_t const&) ; +0x60, 0x30717c\nBL              __cxa_end_cleanup                                      ; +0x64, 0x307180\nMOV             R0, R4                                                 ; +0x68, 0x307184\nPOP             {R3-R7,PC}                                             ; +0x6a, 0x307186\nLDR             R3, [R4]                                               ; +0x6c, 0x307188\nMOV             R0, R4                                                 ; +0x6e, 0x30718a\nLDR             R3, [R3,#8]                                            ; +0x70, 0x30718c\nBLX             R3                                                     ; +0x72, 0x30718e\nMOV             R0, R5                                                 ; +0x74, 0x307190\nPOP             {R3-R7,PC}                                             ; +0x76, 0x307192", "xrefs": [], "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"}