{"type": "func", "start": 5370338544, "end": 5370339026, "name": "GameObject::commonSetup", "pseudocode": "// \n// GameObject::commonSetup from 0x14018dcf0 to 0x14018ded2 (482 bytes)\n// \n// 31 xrefs:\n// > EditorUI::alignObjects @ 0x1401220a7\n// > EndPortalObject::init @ 0x140137da9\n// > GameObject::createWithKey @ 0x14018c18b\n// > GameObject::createWithKey @ 0x14018c472\n// > GameObject::createWithKey @ 0x14018d1d7\n// > GameObject::createWithFrame @ 0x14018dc66\n// > GameObject::initWithTexture @ 0x14018dcda\n// > EnhancedGameObject::init @ 0x1401a479d\n// > TextGameObject::create @ 0x1401a754f\n// > LevelPage::addSecretCoin @ 0x14031c403\n// > PlayerObject::init @ 0x140386957\n// > PlayLayer::createCheckpoint @ 0x1403b53ac\n// > GradientTriggerObject::init @ 0x140499244\n// > ParticleGameObject::init @ 0x14049fc44\n// > AnimatedGameObject::init @ 0x1404a2d9e\n// > EffectGameObject::init @ 0x1404a589d\n// > KeyframeAnimTriggerObject::init @ 0x1404b15b4\n// > StartPosObject::init @ 0x1404b1fcd\n// > LabelGameObject::init @ 0x1404b3474\n// > KeyframeGameObject::init @ 0x1404b5454\n// > EventLinkTrigger::init @ 0x1404b8854\n// > SpawnTriggerGameObject::init @ 0x1404b90a4\n// > CheckpointGameObject::init @ 0x1404b9db4\n// > EndTriggerGameObject::init @ 0x1404bcc84\n// > UISettingsGameObject::init @ 0x1404bd294\n// > AudioLineGuideGameObject::init @ 0x1404c1474\n// > PlayerControlGameObject::init @ 0x1404c27d4\n// > ObjectControlGameObject::init @ 0x1404c2d84\n// > SpawnParticleGameObject::init @ 0x1404c3554\n// > RotateGameplayGameObject::init @ 0x1404c3f14\n// > <???> @ 0x1406cb8a4\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=3\nvoid GameObject::commonSetup(GameObject *a1)\n{\n  __int64 v2; // rcx\n  char v3; // al\n  __int64 v4; // rax\n  GJSpriteColor *m_baseColor; // rdx\n  int v6; // eax\n  void *v7; // [rsp+30h] [rbp+8h]\n\n  v2 = qword_1406C2ED8;\n  if ( !qword_1406C2ED8 )\n  {\n    v7 = operator new(0x668u);\n    qword_1406C2ED8 = sub_14017AB00((__int64)v7);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n    v2 = qword_1406C2ED8;\n  }\n  v3 = *(_BYTE *)(v2 + 698);\n  a1->m_editorEnabled = v3;\n  if ( !v3 )\n  {\n    v4 = *(_QWORD *)(v2 + 520);\n    if ( v4 )\n      a1->m_goEffectManager = *(GJEffectManager **)(v4 + 2384);\n  }\n  m_baseColor = a1->m_baseColor;\n  if ( !m_baseColor )\n  {\n    m_baseColor = (GJSpriteColor *)operator new(0x28u);\n    *(_QWORD *)&m_baseColor->m_colorID = 0;\n    m_baseColor->m_opacity = 1.0;\n    m_baseColor->m_baseOpacity = 1.0;\n    m_baseColor->m_hsv = (cocos2d::ccHSVValue)xmmword_1406BA148;\n    *(_WORD *)&m_baseColor->m_usesHSV = 0;\n    *(_WORD *)&m_baseColor->m_customColor.r = -1;\n    m_baseColor->m_customColor.b = -1;\n    a1->m_baseColor = m_baseColor;\n  }\n  m_baseColor->m_defaultColorID = 1004;\n  m_baseColor->m_colorID = 0;\n  a1->m_opacityMod = 1.0;\n  a1->m_defaultZOrder = 2;\n  *(_DWORD *)&a1->m_enterType = -1;\n  a1->m_unk3E8 = 1;\n  qword_1406C2EE0 = 214013 * qword_1406C2EE0 + 2531011;\n  a1->m_varianceIndex = (int)(float)((float)((float)(((unsigned __int64)qword_1406C2EE0 >> 16) & 0x7FFF) / 32767.0)\n                                   * 1900.0);\n  a1->m_width = a1->m_obRect.size.width;\n  a1->m_height = a1->m_obRect.size.height;\n  a1->m_spriteWidthScale = 1.0;\n  a1->m_spriteHeightScale = 1.0;\n  v6 = dword_1406BA158;\n  a1->m_uniqueID = dword_1406BA158;\n  a1->m_unknown5 = v6;\n  dword_1406BA158 = v6 + 1;\n  a1->m_startScaleX = 1.0;\n  a1->m_startScaleY = 1.0;\n  *(_QWORD *)&a1->m_startRotationX = 0;\n  ((void (__fastcall *)(GameObject *))a1->setScaleX)(a1);\n  ((void (__fastcall *)(GameObject *))a1->setScaleY)(a1);\n  a1->m_isActivated = 0;\n  a1->m_isDirty = 1;\n  a1->m_isObjectRectDirty = 1;\n}", "assembly": "; \n; GameObject::commonSetup from 0x14018dcf0 to 0x14018ded2 (482 bytes)\n; \n; 31 xrefs:\n; > EditorUI::alignObjects @ 0x1401220a7\n; > EndPortalObject::init @ 0x140137da9\n; > GameObject::createWithKey @ 0x14018c18b\n; > GameObject::createWithKey @ 0x14018c472\n; > GameObject::createWithKey @ 0x14018d1d7\n; > GameObject::createWithFrame @ 0x14018dc66\n; > GameObject::initWithTexture @ 0x14018dcda\n; > EnhancedGameObject::init @ 0x1401a479d\n; > TextGameObject::create @ 0x1401a754f\n; > LevelPage::addSecretCoin @ 0x14031c403\n; > PlayerObject::init @ 0x140386957\n; > PlayLayer::createCheckpoint @ 0x1403b53ac\n; > GradientTriggerObject::init @ 0x140499244\n; > ParticleGameObject::init @ 0x14049fc44\n; > AnimatedGameObject::init @ 0x1404a2d9e\n; > EffectGameObject::init @ 0x1404a589d\n; > KeyframeAnimTriggerObject::init @ 0x1404b15b4\n; > StartPosObject::init @ 0x1404b1fcd\n; > LabelGameObject::init @ 0x1404b3474\n; > KeyframeGameObject::init @ 0x1404b5454\n; > EventLinkTrigger::init @ 0x1404b8854\n; > SpawnTriggerGameObject::init @ 0x1404b90a4\n; > CheckpointGameObject::init @ 0x1404b9db4\n; > EndTriggerGameObject::init @ 0x1404bcc84\n; > UISettingsGameObject::init @ 0x1404bd294\n; > AudioLineGuideGameObject::init @ 0x1404c1474\n; > PlayerControlGameObject::init @ 0x1404c27d4\n; > ObjectControlGameObject::init @ 0x1404c2d84\n; > SpawnParticleGameObject::init @ 0x1404c3554\n; > RotateGameplayGameObject::init @ 0x1404c3f14\n; > <???> @ 0x1406cb8a4\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, 0x14018dcf0\npush    rdi                                                            ; +0x5, 0x14018dcf5\nsub     rsp, 20h                                                       ; +0x6, 0x14018dcf6\nmov     rbx, rcx                                                       ; +0xa, 0x14018dcfa\nmov     rcx, cs:qword_1406C2ED8                                        ; +0xd, 0x14018dcfd\ntest    rcx, rcx                                                       ; +0x14, 0x14018dd04\njnz     short loc_14018DD38                                            ; +0x17, 0x14018dd07\nmov     ecx, 668h; Size                                                ; +0x19, 0x14018dd09\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x1e, 0x14018dd0e\nmov     [rsp+28h+arg_0], rax                                           ; +0x23, 0x14018dd13\nmov     rcx, rax                                                       ; +0x28, 0x14018dd18\ncall    sub_14017AB00                                                  ; +0x2b, 0x14018dd1b\nnop                                                                    ; +0x30, 0x14018dd20\nmov     cs:qword_1406C2ED8, rax                                        ; +0x31, 0x14018dd21\nmov     rdx, [rax]                                                     ; +0x38, 0x14018dd28\nmov     rcx, rax                                                       ; +0x3b, 0x14018dd2b\ncall    qword ptr [rdx+48h]                                            ; +0x3e, 0x14018dd2e\nmov     rcx, cs:qword_1406C2ED8                                        ; +0x41, 0x14018dd31\nmovzx   eax, byte ptr [rcx+2BAh]                                       ; +0x48, 0x14018dd38\nmov     [rbx+28Dh], al                                                 ; +0x4f, 0x14018dd3f\ntest    al, al                                                         ; +0x55, 0x14018dd45\njnz     short loc_14018DD63                                            ; +0x57, 0x14018dd47\nmov     rax, [rcx+208h]                                                ; +0x59, 0x14018dd49\ntest    rax, rax                                                       ; +0x60, 0x14018dd50\njz      short loc_14018DD63                                            ; +0x63, 0x14018dd53\nmov     rax, [rax+950h]                                                ; +0x65, 0x14018dd55\nmov     [rbx+508h], rax                                                ; +0x6c, 0x14018dd5c\nmov     rdx, [rbx+450h]                                                ; +0x73, 0x14018dd63\nxor     edi, edi                                                       ; +0x7a, 0x14018dd6a\ntest    rdx, rdx                                                       ; +0x7c, 0x14018dd6c\njnz     short loc_14018DDBD                                            ; +0x7f, 0x14018dd6f\nlea     ecx, [rdx+28h]; Size                                           ; +0x81, 0x14018dd71\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x84, 0x14018dd74\nmov     rdx, rax                                                       ; +0x89, 0x14018dd79\nmov     [rsp+28h+arg_0], rax                                           ; +0x8c, 0x14018dd7c\nmov     [rax], rdi                                                     ; +0x91, 0x14018dd81\nmov     dword ptr [rax+8], 3F800000h                                   ; +0x94, 0x14018dd84\nmov     dword ptr [rax+0Ch], 3F800000h                                 ; +0x9b, 0x14018dd8b\nmovups  xmm0, cs:xmmword_1406BA148                                     ; +0xa2, 0x14018dd92\nmovups  xmmword ptr [rax+10h], xmm0                                    ; +0xa9, 0x14018dd99\nmov     [rax+20h], di                                                  ; +0xad, 0x14018dd9d\nmovzx   ecx, cs:word_140529A70                                         ; +0xb1, 0x14018dda1\nmov     [rax+22h], cx                                                  ; +0xb8, 0x14018dda8\nmovzx   eax, cs:byte_140529A72                                         ; +0xbc, 0x14018ddac\nmov     [rdx+24h], al                                                  ; +0xc3, 0x14018ddb3\nmov     [rbx+450h], rdx                                                ; +0xc6, 0x14018ddb6\nmov     eax, 3ECh                                                      ; +0xcd, 0x14018ddbd\nmov     [rdx+4], eax                                                   ; +0xd2, 0x14018ddc2\nmov     [rdx], edi                                                     ; +0xd5, 0x14018ddc5\nmov     dword ptr [rbx+43Ch], 3F800000h                                ; +0xd7, 0x14018ddc7\nmov     dword ptr [rbx+420h], 2                                        ; +0xe1, 0x14018ddd1\nmov     dword ptr [rbx+3F8h], 0FFFFFFFFh                               ; +0xeb, 0x14018dddb\nmov     byte ptr [rbx+400h], 1                                         ; +0xf5, 0x14018dde5\nimul    rax, cs:qword_1406C2EE0, 343FDh                                ; +0xfc, 0x14018ddec\nadd     rax, 269EC3h                                                   ; +0x107, 0x14018ddf7\nmov     cs:qword_1406C2EE0, rax                                        ; +0x10d, 0x14018ddfd\nshr     rax, 10h                                                       ; +0x114, 0x14018de04\nand     eax, 7FFFh                                                     ; +0x118, 0x14018de08\nmovd    xmm0, eax                                                      ; +0x11d, 0x14018de0d\ncvtdq2ps xmm0, xmm0                                                    ; +0x121, 0x14018de11\ndivss   xmm0, cs:dword_140623644                                       ; +0x124, 0x14018de14\nmulss   xmm0, cs:dword_140623568                                       ; +0x12c, 0x14018de1c\ncvttss2si eax, xmm0                                                    ; +0x134, 0x14018de24\nmov     [rbx+3F4h], ax                                                 ; +0x138, 0x14018de28\nmov     eax, [rbx+1B0h]                                                ; +0x13f, 0x14018de2f\nmov     [rbx+2FCh], eax                                                ; +0x145, 0x14018de35\nmov     eax, [rbx+1B4h]                                                ; +0x14b, 0x14018de3b\nmov     [rbx+300h], eax                                                ; +0x151, 0x14018de41\nmov     dword ptr [rbx+394h], 3F800000h                                ; +0x157, 0x14018de47\nmov     dword ptr [rbx+398h], 3F800000h                                ; +0x161, 0x14018de51\nmov     eax, cs:dword_1406BA158                                        ; +0x16b, 0x14018de5b\nmov     [rbx+39Ch], eax                                                ; +0x171, 0x14018de61\nmov     [rbx+34h], eax                                                 ; +0x177, 0x14018de67\ninc     eax                                                            ; +0x17a, 0x14018de6a\nmov     cs:dword_1406BA158, eax                                        ; +0x17c, 0x14018de6c\nmov     dword ptr [rbx+3DCh], 3F800000h                                ; +0x182, 0x14018de72\nmov     dword ptr [rbx+3E0h], 3F800000h                                ; +0x18c, 0x14018de7c\nmov     [rbx+3D4h], rdi                                                ; +0x196, 0x14018de86\nmov     rax, [rbx]                                                     ; +0x19d, 0x14018de8d\nmovss   xmm1, cs:flt_140622C24                                         ; +0x1a0, 0x14018de90\nmov     rcx, rbx                                                       ; +0x1a8, 0x14018de98\ncall    qword ptr [rax+78h]                                            ; +0x1ab, 0x14018de9b\nmov     rax, [rbx]                                                     ; +0x1ae, 0x14018de9e\nmovss   xmm1, cs:flt_140622C24                                         ; +0x1b1, 0x14018dea1\nmov     rcx, rbx                                                       ; +0x1b9, 0x14018dea9\ncall    qword ptr [rax+88h]                                            ; +0x1bc, 0x14018deac\nmov     [rbx+305h], dil                                                ; +0x1c2, 0x14018deb2\nmov     byte ptr [rbx+350h], 1                                         ; +0x1c9, 0x14018deb9\nmov     byte ptr [rbx+368h], 1                                         ; +0x1d0, 0x14018dec0\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x1d7, 0x14018dec7\nadd     rsp, 20h                                                       ; +0x1dc, 0x14018decc\npop     rdi                                                            ; +0x1e0, 0x14018ded0\nretn                                                                   ; +0x1e1, 0x14018ded1", "xrefs": ["EditorUI::alignObjects @ 0x1401220a7", "EndPortalObject::init @ 0x140137da9", "GameObject::createWithKey @ 0x14018c18b", "GameObject::createWithKey @ 0x14018c472", "GameObject::createWithKey @ 0x14018d1d7", "GameObject::createWithFrame @ 0x14018dc66", "GameObject::initWithTexture @ 0x14018dcda", "EnhancedGameObject::init @ 0x1401a479d", "TextGameObject::create @ 0x1401a754f", "LevelPage::addSecretCoin @ 0x14031c403", "PlayerObject::init @ 0x140386957", "PlayLayer::createCheckpoint @ 0x1403b53ac", "GradientTriggerObject::init @ 0x140499244", "ParticleGameObject::init @ 0x14049fc44", "AnimatedGameObject::init @ 0x1404a2d9e", "EffectGameObject::init @ 0x1404a589d", "KeyframeAnimTriggerObject::init @ 0x1404b15b4", "StartPosObject::init @ 0x1404b1fcd", "LabelGameObject::init @ 0x1404b3474", "KeyframeGameObject::init @ 0x1404b5454", "EventLinkTrigger::init @ 0x1404b8854", "SpawnTriggerGameObject::init @ 0x1404b90a4", "CheckpointGameObject::init @ 0x1404b9db4", "EndTriggerGameObject::init @ 0x1404bcc84", "UISettingsGameObject::init @ 0x1404bd294", "AudioLineGuideGameObject::init @ 0x1404c1474", "PlayerControlGameObject::init @ 0x1404c27d4", "ObjectControlGameObject::init @ 0x1404c2d84", "SpawnParticleGameObject::init @ 0x1404c3554", "RotateGameplayGameObject::init @ 0x1404c3f14", "<???> @ 0x1406cb8a4"], "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"}