{"type": "func", "start": 4301175888, "end": 4301176138, "name": "GJMGLayer::create", "pseudocode": "// \n// GJMGLayer::create from 0x1005ebc50 to 0x1005ebd4a (250 bytes)\n// \n// 4 xrefs:\n// > GJBaseGameLayer::swapMiddleground @ 0x100114a96\n// > GJBaseGameLayer::createMiddleground @ 0x100114b66\n// > GJBaseGameLayer::asyncMGLoaded @ 0x100114c06\n// > GJBaseGameLayer::syncBGTextures @ 0x10015900f\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\nGJMGLayer *__fastcall GJMGLayer::create(int a1)\n{\n  char *v1; // rbx\n\n  v1 = (char *)operator new(0x1E8u);\n  cocos2d::CCLayer::CCLayer((__int64)v1);\n  *(_QWORD *)v1 = off_100979BA0;\n  *((_QWORD *)v1 + 40) = off_10097A028;\n  *((_QWORD *)v1 + 41) = &off_10097A098;\n  *((_QWORD *)v1 + 42) = off_10097A0B0;\n  *((_QWORD *)v1 + 43) = off_10097A0D0;\n  *((_QWORD *)v1 + 44) = off_10097A0F0;\n  *((_QWORD *)v1 + 54) = 0;\n  v1[440] = 0;\n  *((_DWORD *)v1 + 111) = 0;\n  *(_OWORD *)(v1 + 408) = 0;\n  *((_DWORD *)v1 + 106) = 0;\n  *((_WORD *)v1 + 224) = 257;\n  *((_DWORD *)v1 + 113) = 0;\n  *(_DWORD *)(v1 + 455) = 0;\n  *((_OWORD *)v1 + 29) = 0;\n  *((_QWORD *)v1 + 60) = 0;\n  if ( GJMGLayer::init((GJMGLayer *)v1, a1) )\n  {\n    cocos2d::CCObject::autorelease((cocos2d::CCObject *)v1);\n  }\n  else\n  {\n    (*(void (__fastcall **)(char *))(*(_QWORD *)v1 + 16LL))(v1);\n    return nullptr;\n  }\n  return (GJMGLayer *)v1;\n}", "assembly": "; \n; GJMGLayer::create from 0x1005ebc50 to 0x1005ebd4a (250 bytes)\n; \n; 4 xrefs:\n; > GJBaseGameLayer::swapMiddleground @ 0x100114a96\n; > GJBaseGameLayer::createMiddleground @ 0x100114b66\n; > GJBaseGameLayer::asyncMGLoaded @ 0x100114c06\n; > GJBaseGameLayer::syncBGTextures @ 0x10015900f\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    rbp                                                            ; +0x0, 0x1005ebc50\nmov     rbp, rsp                                                       ; +0x1, 0x1005ebc51\npush    r14                                                            ; +0x4, 0x1005ebc54\npush    rbx                                                            ; +0x6, 0x1005ebc56\nmov     r14d, edi                                                      ; +0x7, 0x1005ebc57\nmov     edi, 1E8h; __sz                                                ; +0xa, 0x1005ebc5a\ncall    __Znwm; operator new(ulong)                                    ; +0xf, 0x1005ebc5f\nmov     rbx, rax                                                       ; +0x14, 0x1005ebc64\nmov     rdi, rax                                                       ; +0x17, 0x1005ebc67\ncall    cocos2d__CCLayer__CCLayer                                      ; +0x1a, 0x1005ebc6a\nlea     rax, off_100979BA0                                             ; +0x1f, 0x1005ebc6f\nmov     [rbx], rax                                                     ; +0x26, 0x1005ebc76\nlea     rax, off_10097A028                                             ; +0x29, 0x1005ebc79\nmov     [rbx+140h], rax                                                ; +0x30, 0x1005ebc80\nlea     rax, off_10097A098                                             ; +0x37, 0x1005ebc87\nmov     [rbx+148h], rax                                                ; +0x3e, 0x1005ebc8e\nlea     rax, off_10097A0B0                                             ; +0x45, 0x1005ebc95\nmov     [rbx+150h], rax                                                ; +0x4c, 0x1005ebc9c\nlea     rax, off_10097A0D0                                             ; +0x53, 0x1005ebca3\nmov     [rbx+158h], rax                                                ; +0x5a, 0x1005ebcaa\nlea     rax, off_10097A0F0                                             ; +0x61, 0x1005ebcb1\nmov     [rbx+160h], rax                                                ; +0x68, 0x1005ebcb8\nmov     qword ptr [rbx+1B0h], 0                                        ; +0x6f, 0x1005ebcbf\nmov     byte ptr [rbx+1B8h], 0                                         ; +0x7a, 0x1005ebcca\nmov     dword ptr [rbx+1BCh], 0                                        ; +0x81, 0x1005ebcd1\nxorps   xmm0, xmm0                                                     ; +0x8b, 0x1005ebcdb\nmovups  xmmword ptr [rbx+198h], xmm0                                   ; +0x8e, 0x1005ebcde\nmov     dword ptr [rbx+1A8h], 0                                        ; +0x95, 0x1005ebce5\nmov     word ptr [rbx+1C0h], 101h                                      ; +0x9f, 0x1005ebcef\nmov     dword ptr [rbx+1C4h], 0                                        ; +0xa8, 0x1005ebcf8\nmov     dword ptr [rbx+1C7h], 0                                        ; +0xb2, 0x1005ebd02\nmovups  xmmword ptr [rbx+1D0h], xmm0                                   ; +0xbc, 0x1005ebd0c\nmov     qword ptr [rbx+1E0h], 0                                        ; +0xc3, 0x1005ebd13\nmov     rdi, rbx                                                       ; +0xce, 0x1005ebd1e\nmov     esi, r14d                                                      ; +0xd1, 0x1005ebd21\ncall    GJMGLayer__init                                                ; +0xd4, 0x1005ebd24\ntest    al, al                                                         ; +0xd9, 0x1005ebd29\njz      short loc_1005EBD37                                            ; +0xdb, 0x1005ebd2b\nmov     rdi, rbx                                                       ; +0xdd, 0x1005ebd2d\ncall    cocos2d__CCObject__autorelease                                 ; +0xe0, 0x1005ebd30\njmp     short loc_1005EBD42                                            ; +0xe5, 0x1005ebd35\nmov     rax, [rbx]                                                     ; +0xe7, 0x1005ebd37\nmov     rdi, rbx                                                       ; +0xea, 0x1005ebd3a\ncall    qword ptr [rax+10h]                                            ; +0xed, 0x1005ebd3d\nxor     ebx, ebx                                                       ; +0xf0, 0x1005ebd40\nmov     rax, rbx                                                       ; +0xf2, 0x1005ebd42\npop     rbx                                                            ; +0xf5, 0x1005ebd45\npop     r14                                                            ; +0xf6, 0x1005ebd46\npop     rbp                                                            ; +0xf8, 0x1005ebd48\nretn                                                                   ; +0xf9, 0x1005ebd49", "xrefs": ["GJBaseGameLayer::swapMiddleground @ 0x100114a96", "GJBaseGameLayer::createMiddleground @ 0x100114b66", "GJBaseGameLayer::asyncMGLoaded @ 0x100114c06", "GJBaseGameLayer::syncBGTextures @ 0x10015900f"], "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"}