{"type": "func", "start": 5369987680, "end": 5369988026, "name": "EndPortalObject::setPosition", "pseudocode": "// \n// EndPortalObject::setPosition from 0x140138260 to 0x1401383ba (346 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x140556bd8\n// > <???> @ 0x1406ca0a4\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 EndPortalObject::setPosition(EndPortalObject *a1, const cocos2d::CCPoint *a2)\n{\n  float v4; // xmm8_4\n  __int64 v5; // rax\n  const cocos2d::CCPoint *v6; // rax\n  char v7; // [rsp+60h] [rbp+8h] BYREF\n  void *v8; // [rsp+70h] [rbp+18h] BYREF\n  cocos2d::CCPoint v9; // [rsp+78h] [rbp+20h] BYREF\n\n  GameObject::setPosition(a1, a2);\n  if ( a1->m_gradientBar )\n  {\n    if ( a1->m_flippedX )\n      v4 = -1.0;\n    else\n      v4 = 1.0;\n    v5 = qword_1406C2ED8;\n    if ( !qword_1406C2ED8 )\n    {\n      v8 = operator new(0x668u);\n      qword_1406C2ED8 = sub_14017AB00(v8);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n      v5 = qword_1406C2ED8;\n    }\n    cocos2d::CCPoint::CCPoint(&v9, (float)(-14.0 - (float)(15.0 / *(float *)(*(_QWORD *)(v5 + 520) + 424LL))) * v4, 0.0);\n    cocos2d::CCPoint::operator+(a2, &v7);\n    a1->m_gradientBar->setPosition_0(a1->m_gradientBar, (const cocos2d::CCPoint *)&v7);\n  }\n  if ( a1->m_particle )\n  {\n    cocos2d::CCPoint::operator*(&a1->m_particleOffset, &v7);\n    v6 = a1->getPosition_0(a1);\n    cocos2d::CCPoint::operator+(v6, &v8);\n    a1->m_particle->setPosition_0(a1->m_particle, (const cocos2d::CCPoint *)&v8);\n  }\n}", "assembly": "; \n; EndPortalObject::setPosition from 0x140138260 to 0x1401383ba (346 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x140556bd8\n; > <???> @ 0x1406ca0a4\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    rbx                                                            ; +0x0, 0x140138260\npush    rsi                                                            ; +0x2, 0x140138262\npush    rdi                                                            ; +0x3, 0x140138263\nsub     rsp, 40h                                                       ; +0x4, 0x140138264\nmovaps  [rsp+58h+var_28], xmm6                                         ; +0x8, 0x140138268\nmovaps  [rsp+58h+var_38], xmm8                                         ; +0xd, 0x14013826d\nmov     rsi, rdx                                                       ; +0x13, 0x140138273\nmov     rbx, rcx                                                       ; +0x16, 0x140138276\ncall    GameObject__setPosition                                        ; +0x19, 0x140138279\nmovss   xmm6, cs:dword_1406236F0                                       ; +0x1e, 0x14013827e\ncmp     qword ptr [rbx+550h], 0                                        ; +0x26, 0x140138286\njz      loc_140138343                                                  ; +0x2e, 0x14013828e\ncmp     byte ptr [rbx+558h], 0                                         ; +0x34, 0x140138294\njz      short loc_1401382A3                                            ; +0x3b, 0x14013829b\nmovaps  xmm8, xmm6                                                     ; +0x3d, 0x14013829d\njmp     short loc_1401382AC                                            ; +0x41, 0x1401382a1\nmovss   xmm8, cs:flt_140622C24                                         ; +0x43, 0x1401382a3\nmov     rax, cs:qword_1406C2ED8                                        ; +0x4c, 0x1401382ac\ntest    rax, rax                                                       ; +0x53, 0x1401382b3\njnz     short loc_1401382E7                                            ; +0x56, 0x1401382b6\nmov     ecx, 668h; Size                                                ; +0x58, 0x1401382b8\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x5d, 0x1401382bd\nmov     [rsp+58h+arg_10], rax                                          ; +0x62, 0x1401382c2\nmov     rcx, rax                                                       ; +0x67, 0x1401382c7\ncall    sub_14017AB00                                                  ; +0x6a, 0x1401382ca\nnop                                                                    ; +0x6f, 0x1401382cf\nmov     cs:qword_1406C2ED8, rax                                        ; +0x70, 0x1401382d0\nmov     rdx, [rax]                                                     ; +0x77, 0x1401382d7\nmov     rcx, rax                                                       ; +0x7a, 0x1401382da\ncall    qword ptr [rdx+48h]                                            ; +0x7d, 0x1401382dd\nmov     rax, cs:qword_1406C2ED8                                        ; +0x80, 0x1401382e0\nmov     rax, [rax+208h]                                                ; +0x87, 0x1401382e7\nmovss   xmm0, cs:dword_1406230E0                                       ; +0x8e, 0x1401382ee\ndivss   xmm0, dword ptr [rax+1A8h]                                     ; +0x96, 0x1401382f6\nmovss   xmm1, cs:dword_140623864                                       ; +0x9e, 0x1401382fe\nsubss   xmm1, xmm0                                                     ; +0xa6, 0x140138306\nmulss   xmm1, xmm8                                                     ; +0xaa, 0x14013830a\nxorps   xmm2, xmm2                                                     ; +0xaf, 0x14013830f\nlea     rcx, [rsp+58h+arg_18]                                          ; +0xb2, 0x140138312\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0xb7, 0x140138317\nmov     r8, rax                                                        ; +0xbd, 0x14013831d\nlea     rdx, [rsp+58h+arg_0]                                           ; +0xc0, 0x140138320\nmov     rcx, rsi                                                       ; +0xc5, 0x140138325\ncall    cs:??HCCPoint@cocos2d@@QEBA?AV01@AEBV01@@Z; cocos2d::CCPoint::operator+(cocos2d::CCPoint const &) ; +0xc8, 0x140138328\nmov     rcx, [rbx+550h]                                                ; +0xce, 0x14013832e\nmov     rax, [rcx]                                                     ; +0xd5, 0x140138335\nlea     rdx, [rsp+58h+arg_0]                                           ; +0xd8, 0x140138338\ncall    qword ptr [rax+0B8h]                                           ; +0xdd, 0x14013833d\ncmp     qword ptr [rbx+308h], 0                                        ; +0xe3, 0x140138343\njz      short loc_1401383A7                                            ; +0xeb, 0x14013834b\ncmp     byte ptr [rbx+558h], 0                                         ; +0xed, 0x14013834d\njnz     short loc_14013835E                                            ; +0xf4, 0x140138354\nmovss   xmm6, cs:flt_140622C24                                         ; +0xf6, 0x140138356\nlea     rcx, [rbx+334h]                                                ; +0xfe, 0x14013835e\nmovaps  xmm2, xmm6                                                     ; +0x105, 0x140138365\nlea     rdx, [rsp+58h+arg_0]                                           ; +0x108, 0x140138368\ncall    cs:??DCCPoint@cocos2d@@QEBA?AV01@M@Z; cocos2d::CCPoint::operator*(float) ; +0x10d, 0x14013836d\nmov     rax, [rbx]                                                     ; +0x113, 0x140138373\nmov     rcx, rbx                                                       ; +0x116, 0x140138376\ncall    qword ptr [rax+0C8h]                                           ; +0x119, 0x140138379\nlea     r8, [rsp+58h+arg_0]                                            ; +0x11f, 0x14013837f\nlea     rdx, [rsp+58h+arg_10]                                          ; +0x124, 0x140138384\nmov     rcx, rax                                                       ; +0x129, 0x140138389\ncall    cs:??HCCPoint@cocos2d@@QEBA?AV01@AEBV01@@Z; cocos2d::CCPoint::operator+(cocos2d::CCPoint const &) ; +0x12c, 0x14013838c\nmov     rcx, [rbx+308h]                                                ; +0x132, 0x140138392\nmov     rax, [rcx]                                                     ; +0x139, 0x140138399\nlea     rdx, [rsp+58h+arg_10]                                          ; +0x13c, 0x14013839c\ncall    qword ptr [rax+0B8h]                                           ; +0x141, 0x1401383a1\nmovaps  xmm6, [rsp+58h+var_28]                                         ; +0x147, 0x1401383a7\nmovaps  xmm8, [rsp+58h+var_38]                                         ; +0x14c, 0x1401383ac\nadd     rsp, 40h                                                       ; +0x152, 0x1401383b2\npop     rdi                                                            ; +0x156, 0x1401383b6\npop     rsi                                                            ; +0x157, 0x1401383b7\npop     rbx                                                            ; +0x158, 0x1401383b8\nretn                                                                   ; +0x159, 0x1401383b9", "xrefs": ["<???> @ 0x140556bd8", "<???> @ 0x1406ca0a4"], "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"}