{"type": "func", "start": 5370884480, "end": 5370884967, "name": "GJBaseGameLayer::updateDualGround", "pseudocode": "// \n// GJBaseGameLayer::updateDualGround from 0x140213180 to 0x140213367 (487 bytes)\n// \n// 8 xrefs:\n// > GJBaseGameLayer::setupLevelStart @ 0x140212a3b\n// > GJBaseGameLayer::playerWillSwitchMode @ 0x140212faa\n// > GJBaseGameLayer::toggleDualMode @ 0x140216df8\n// > GJBaseGameLayer::updateZoom @ 0x140235e4c\n// > GJBaseGameLayer::exitStaticCamera @ 0x14023fabb\n// > PlayLayer::loadFromCheckpoint @ 0x1403b7eab\n// > CameraTriggerGameObject::triggerObject @ 0x1404bdafe\n// > <???> @ 0x1406cd068\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\nvoid GJBaseGameLayer::updateDualGround(GJBaseGameLayer *a1, PlayerObject *a2, int a3, bool a4, float a5)\n{\n  bool m_isDualMode; // bl\n  __int64 v8; // rcx\n  bool v9; // r9\n  GameObject *v10; // r10\n  int v11; // r11d\n  float GroundHeightForMode; // xmm0_4\n  float v13; // xmm2_4\n  PlayerObject *m_player2; // rcx\n  int v15; // edx\n  float v16; // xmm1_4\n  float v17; // [rsp+20h] [rbp-38h]\n  int v18; // [rsp+70h] [rbp+18h] BYREF\n\n  m_isDualMode = a1->m_gameState.m_isDualMode;\n  if ( (unsigned int)(a3 - 23) > 1 )\n    a1->m_gameState.m_dualRelated = a3;\n  GroundHeightForMode = GJBaseGameLayer::getGroundHeightForMode(a1, a3);\n  v13 = GroundHeightForMode;\n  if ( m_isDualMode )\n  {\n    if ( GroundHeightForMode == 240.0 )\n      v13 = 270.0;\n    m_player2 = *(PlayerObject **)(v8 + 3488);\n    if ( a2->m_uniqueID == m_player2->m_uniqueID )\n      m_player2 = a1->m_player2;\n    if ( m_player2->m_isShip || m_player2->m_isBird || m_player2->m_isDart || m_player2->m_isSwing )\n    {\n      v15 = 5;\n    }\n    else\n    {\n      v15 = 6;\n      if ( m_player2->m_isBall )\n        v15 = 16;\n    }\n    v13 = fmaxf(GJBaseGameLayer::getGroundHeightForMode(a1, v15), v13);\n  }\n  if ( a1->m_gameState.m_isFreeMode || v13 == 270.0 && v11 != 33 && !m_isDualMode )\n  {\n    a1->m_gameState.m_unkBool7 = 0;\n    if ( a1->m_gameState.m_unkBool1 )\n    {\n      v18 = 11;\n      sub_14024AC30(&a1->m_gameState.m_tweenActions, &v18);\n      v18 = 13;\n      sub_14024AC30(&a1->m_gameState.m_tweenActions, &v18);\n      a1->m_gameState.m_unkPoint6.y = 0.0;\n      a1->m_gameState.m_unkPoint8.y = 0.0;\n      a1->m_gameState.m_unkPoint17.y = 0.0;\n      a1->m_gameState.m_unkPoint18.y = 0.0;\n      a1->m_gameState.m_unkPoint22.y = 0.0;\n    }\n    v16 = 0.40000001;\n    if ( a1->m_gameState.m_isDualMode )\n      v16 = 0.32000002;\n    GJGameState::tweenValue(&a1->m_gameState, a1->m_gameState.m_unkFloat9, 0.0, 25, v16, 1, 1.5, -1, -1);\n  }\n  else\n  {\n    GJBaseGameLayer::animateInDualGroundNew(a1, v10, v13, v9, v17);\n  }\n}", "assembly": "; \n; GJBaseGameLayer::updateDualGround from 0x140213180 to 0x140213367 (487 bytes)\n; \n; 8 xrefs:\n; > GJBaseGameLayer::setupLevelStart @ 0x140212a3b\n; > GJBaseGameLayer::playerWillSwitchMode @ 0x140212faa\n; > GJBaseGameLayer::toggleDualMode @ 0x140216df8\n; > GJBaseGameLayer::updateZoom @ 0x140235e4c\n; > GJBaseGameLayer::exitStaticCamera @ 0x14023fabb\n; > PlayLayer::loadFromCheckpoint @ 0x1403b7eab\n; > CameraTriggerGameObject::triggerObject @ 0x1404bdafe\n; > <???> @ 0x1406cd068\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_0], rbx                                               ; +0x0, 0x140213180\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x140213185\nmov     [rsp+arg_18], rsi                                              ; +0xa, 0x14021318a\npush    rdi                                                            ; +0xf, 0x14021318f\nsub     rsp, 50h                                                       ; +0x10, 0x140213190\nmovzx   ebx, byte ptr [rcx+422h]                                       ; +0x14, 0x140213194\nxor     ebp, ebp                                                       ; +0x1b, 0x14021319b\nmov     r11d, r8d                                                      ; +0x1d, 0x14021319d\nmov     rsi, rdx                                                       ; +0x20, 0x1402131a0\nmov     rdi, rcx                                                       ; +0x23, 0x1402131a3\ntest    bl, bl                                                         ; +0x26, 0x1402131a6\njz      short loc_1402131B6                                            ; +0x28, 0x1402131a8\nmov     r10, [rcx+408h]                                                ; +0x2a, 0x1402131aa\ntest    r10, r10                                                       ; +0x31, 0x1402131b1\njnz     short loc_1402131C7                                            ; +0x34, 0x1402131b4\nmov     rax, [rcx+400h]                                                ; +0x36, 0x1402131b6\nmov     r10, rbp                                                       ; +0x3d, 0x1402131bd\ntest    rax, rax                                                       ; +0x40, 0x1402131c0\ncmovnz  r10, rax                                                       ; +0x43, 0x1402131c3\nlea     eax, [r8-17h]                                                  ; +0x47, 0x1402131c7\ncmp     eax, 1                                                         ; +0x4b, 0x1402131cb\njbe     short loc_1402131D7                                            ; +0x4e, 0x1402131ce\nmov     [rcx+540h], r11d                                               ; +0x50, 0x1402131d0\nmov     edx, r11d                                                      ; +0x57, 0x1402131d7\ncall    GJBaseGameLayer__getGroundHeightForMode                        ; +0x5a, 0x1402131da\nmovss   xmm1, cs:dword_140623424                                       ; +0x5f, 0x1402131df\nmovaps  xmm2, xmm0                                                     ; +0x67, 0x1402131e7\ntest    bl, bl                                                         ; +0x6a, 0x1402131ea\njz      short loc_140213266                                            ; +0x6c, 0x1402131ec\nucomiss xmm0, cs:dword_140623408                                       ; +0x6e, 0x1402131ee\njp      short loc_1402131FC                                            ; +0x75, 0x1402131f5\njnz     short loc_1402131FC                                            ; +0x77, 0x1402131f7\nmovaps  xmm2, xmm1                                                     ; +0x79, 0x1402131f9\nmov     rcx, [rcx+0DA0h]                                               ; +0x7c, 0x1402131fc\nmov     eax, [rcx+39Ch]                                                ; +0x83, 0x140213203\ncmp     [rsi+39Ch], eax                                                ; +0x89, 0x140213209\njnz     short loc_140213218                                            ; +0x8f, 0x14021320f\nmov     rcx, [rdi+0DA8h]                                               ; +0x91, 0x140213211\ncmp     [rcx+9B9h], bpl                                                ; +0x98, 0x140213218\njnz     short loc_140213252                                            ; +0x9f, 0x14021321f\ncmp     [rcx+9BAh], bpl                                                ; +0xa1, 0x140213221\njnz     short loc_140213252                                            ; +0xa8, 0x140213228\ncmp     [rcx+9BCh], bpl                                                ; +0xaa, 0x14021322a\njnz     short loc_140213252                                            ; +0xb1, 0x140213231\ncmp     [rcx+9C4h], bpl                                                ; +0xb3, 0x140213233\njnz     short loc_140213252                                            ; +0xba, 0x14021323a\ncmp     [rcx+9BBh], bpl                                                ; +0xbc, 0x14021323c\nmov     edx, 6                                                         ; +0xc3, 0x140213243\nmov     eax, 10h                                                       ; +0xc8, 0x140213248\ncmovnz  edx, eax                                                       ; +0xcd, 0x14021324d\njmp     short loc_140213257                                            ; +0xd0, 0x140213250\nmov     edx, 5                                                         ; +0xd2, 0x140213252\nmov     rcx, rdi                                                       ; +0xd7, 0x140213257\ncall    GJBaseGameLayer__getGroundHeightForMode                        ; +0xda, 0x14021325a\nmaxss   xmm0, xmm2                                                     ; +0xdf, 0x14021325f\nmovaps  xmm2, xmm0                                                     ; +0xe3, 0x140213263\ncmp     [rdi+311h], bpl                                                ; +0xe6, 0x140213266\njnz     short loc_140213290                                            ; +0xed, 0x14021326d\nucomiss xmm2, xmm1                                                     ; +0xef, 0x14021326f\njp      short loc_140213280                                            ; +0xf2, 0x140213272\njnz     short loc_140213280                                            ; +0xf4, 0x140213274\ncmp     r11d, 21h ; '!'                                                ; +0xf6, 0x140213276\njz      short loc_140213280                                            ; +0xfa, 0x14021327a\ntest    bl, bl                                                         ; +0xfc, 0x14021327c\njz      short loc_140213290                                            ; +0xfe, 0x14021327e\nmov     rdx, r10                                                       ; +0x100, 0x140213280\nmov     rcx, rdi                                                       ; +0x103, 0x140213283\ncall    GJBaseGameLayer__animateInDualGroundNew                        ; +0x106, 0x140213286\njmp     loc_140213352                                                  ; +0x10b, 0x14021328b\nmov     [rdi+310h], bpl                                                ; +0x110, 0x140213290\ncmp     [rdi+2A0h], bpl                                                ; +0x117, 0x140213297\njz      short loc_1402132F0                                            ; +0x11e, 0x14021329e\nlea     rdx, [rsp+58h+arg_10]                                          ; +0x120, 0x1402132a0\nmov     [rsp+58h+arg_10], 0Bh                                          ; +0x125, 0x1402132a5\nlea     rcx, [rdi+428h]                                                ; +0x12d, 0x1402132ad\ncall    sub_14024AC30                                                  ; +0x134, 0x1402132b4\nlea     rdx, [rsp+58h+arg_10]                                          ; +0x139, 0x1402132b9\nmov     [rsp+58h+arg_10], 0Dh                                          ; +0x13e, 0x1402132be\nlea     rcx, [rdi+428h]                                                ; +0x146, 0x1402132c6\ncall    sub_14024AC30                                                  ; +0x14d, 0x1402132cd\nmov     [rdi+1E4h], ebp                                                ; +0x152, 0x1402132d2\nmov     [rdi+1F4h], ebp                                                ; +0x158, 0x1402132d8\nmov     [rdi+23Ch], ebp                                                ; +0x15e, 0x1402132de\nmov     [rdi+244h], ebp                                                ; +0x164, 0x1402132e4\nmov     [rdi+264h], ebp                                                ; +0x16a, 0x1402132ea\nmovss   xmm1, cs:dword_140622AD0                                       ; +0x170, 0x1402132f0\ncmp     [rdi+422h], bpl                                                ; +0x178, 0x1402132f8\njz      short loc_140213309                                            ; +0x17f, 0x1402132ff\nmovss   xmm1, cs:dword_140622AA8                                       ; +0x181, 0x140213301\nmovss   xmm0, cs:dword_140622D04                                       ; +0x189, 0x140213309\nlea     rcx, [rdi+1A8h]                                                ; +0x191, 0x140213311\nmov     [rsp+58h+var_18], 0FFFFFFFFh                                   ; +0x198, 0x140213318\nmov     r9d, 19h                                                       ; +0x1a0, 0x140213320\nmov     [rsp+58h+var_20], 0FFFFFFFFh                                   ; +0x1a6, 0x140213326\nxorps   xmm2, xmm2                                                     ; +0x1ae, 0x14021332e\nmovss   [rsp+58h+var_28], xmm0                                         ; +0x1b1, 0x140213331\nmov     [rsp+58h+var_30], 1                                            ; +0x1b7, 0x140213337\nmovss   [rsp+58h+var_38], xmm1                                         ; +0x1bf, 0x14021333f\nmovss   xmm1, dword ptr [rdi+424h]                                     ; +0x1c5, 0x140213345\ncall    GJGameState__tweenValue                                        ; +0x1cd, 0x14021334d\nmov     rbx, [rsp+58h+arg_0]                                           ; +0x1d2, 0x140213352\nmov     rbp, [rsp+58h+arg_8]                                           ; +0x1d7, 0x140213357\nmov     rsi, [rsp+58h+arg_18]                                          ; +0x1dc, 0x14021335c\nadd     rsp, 50h                                                       ; +0x1e1, 0x140213361\npop     rdi                                                            ; +0x1e5, 0x140213365\nretn                                                                   ; +0x1e6, 0x140213366", "xrefs": ["GJBaseGameLayer::setupLevelStart @ 0x140212a3b", "GJBaseGameLayer::playerWillSwitchMode @ 0x140212faa", "GJBaseGameLayer::toggleDualMode @ 0x140216df8", "GJBaseGameLayer::updateZoom @ 0x140235e4c", "GJBaseGameLayer::exitStaticCamera @ 0x14023fabb", "PlayLayer::loadFromCheckpoint @ 0x1403b7eab", "CameraTriggerGameObject::triggerObject @ 0x1404bdafe", "<???> @ 0x1406cd068"], "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"}