{"type": "func", "start": 5369891952, "end": 5369892431, "name": "EditorUI::flipObjectsX", "pseudocode": "// \n// EditorUI::flipObjectsX from 0x140120c70 to 0x140120e4f (479 bytes)\n// \n// 6 xrefs:\n// > EditorUI::createSmartObjectsFromTemplate @ 0x14011747b\n// > EditorUI::transformObjectCall_1 @ 0x1401204f1\n// > <???> @ 0x140670144\n// > <???> @ 0x140670178\n// > <???> @ 0x1406c96b4\n// > <???> @ 0x1406c96c0\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 EditorUI::flipObjectsX(EditorUI *a1, cocos2d::CCArray *a2)\n{\n  unsigned int v3; // r14d\n  unsigned int v5; // ebx\n  float v6; // xmm10_4\n  float i; // xmm7_4\n  GameObject *v8; // rdi\n  float MaxX; // xmm6_4\n  float MinX; // xmm0_4\n  GameObject *v11; // rdi\n  float v12; // xmm6_4\n  __int64 v13; // rbx\n  __int64 v14; // rax\n  __int64 v15; // rax\n  cocos2d::CCRect v16; // [rsp+20h] [rbp-78h] BYREF\n  char v17; // [rsp+B0h] [rbp+18h] BYREF\n  cocos2d::CCPoint v18; // [rsp+B8h] [rbp+20h] BYREF\n\n  v3 = 0;\n  v5 = 0;\n  v6 = -9999.0;\n  for ( i = -9999.0; v5 < cocos2d::CCArray::count(a2); ++v5 )\n  {\n    v8 = (GameObject *)cocos2d::CCArray::objectAtIndex(a2, v5);\n    GameObject::updateStartPos(v8);\n    ((void (__fastcall *)(GameObject *, cocos2d::CCRect *))v8->getObjectRect)(v8, &v16);\n    MaxX = cocos2d::CCRect::getMaxX(&v16);\n    MinX = cocos2d::CCRect::getMinX(&v16);\n    v6 = fmaxf(MaxX, v6);\n    if ( i > MinX || i == -9999.0 )\n      i = MinX;\n    EditorUI::transformObject(a1, v8, FlipX, 1);\n  }\n  if ( cocos2d::CCArray::count(a2) )\n  {\n    do\n    {\n      v11 = (GameObject *)cocos2d::CCArray::objectAtIndex(a2, v3);\n      v12 = v6 - (float)(v11->getPosition_0(v11)->x - i);\n      v13 = (__int64)v11->getPosition_0(v11);\n      v14 = (__int64)v11->getPosition_0(v11);\n      cocos2d::CCPoint::CCPoint(&v18, v12, *(float *)(v14 + 4));\n      cocos2d::CCPoint::operator-(v15, &v17, v13);\n      EditorUI::moveObject(a1, v11, (cocos2d::CCPoint)&v17);\n      ++v3;\n    }\n    while ( v3 < cocos2d::CCArray::count(a2) );\n  }\n}", "assembly": "; \n; EditorUI::flipObjectsX from 0x140120c70 to 0x140120e4f (479 bytes)\n; \n; 6 xrefs:\n; > EditorUI::createSmartObjectsFromTemplate @ 0x14011747b\n; > EditorUI::transformObjectCall_1 @ 0x1401204f1\n; > <???> @ 0x140670144\n; > <???> @ 0x140670178\n; > <???> @ 0x1406c96b4\n; > <???> @ 0x1406c96c0\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, 0x140120c70\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x140120c75\npush    rsi                                                            ; +0xa, 0x140120c7a\npush    rdi                                                            ; +0xb, 0x140120c7b\npush    r14                                                            ; +0xc, 0x140120c7c\nsub     rsp, 80h                                                       ; +0xe, 0x140120c7e\nmovaps  [rsp+98h+var_28], xmm6                                         ; +0x15, 0x140120c85\nmov     rbp, rcx                                                       ; +0x1a, 0x140120c8a\nmovaps  [rsp+98h+var_38], xmm7                                         ; +0x1d, 0x140120c8d\nxor     r14d, r14d                                                     ; +0x22, 0x140120c92\nmovaps  [rsp+98h+var_68], xmm10                                        ; +0x25, 0x140120c95\nmov     rcx, rdx                                                       ; +0x2b, 0x140120c9b\nmovaps  [rsp+98h+var_48], xmm8                                         ; +0x2e, 0x140120c9e\nmov     rsi, rdx                                                       ; +0x34, 0x140120ca4\nmovss   xmm8, cs:dword_140623AEC                                       ; +0x37, 0x140120ca7\nmov     ebx, r14d                                                      ; +0x40, 0x140120cb0\nmovaps  xmm10, xmm8                                                    ; +0x43, 0x140120cb3\nmovaps  xmm7, xmm8                                                     ; +0x47, 0x140120cb7\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x4b, 0x140120cbb\ntest    eax, eax                                                       ; +0x51, 0x140120cc1\njz      loc_140120D6F                                                  ; +0x53, 0x140120cc3\nmovaps  [rsp+98h+var_58], xmm9                                         ; +0x59, 0x140120cc9\nmovss   xmm9, cs:flt_140622C24                                         ; +0x5f, 0x140120ccf\nnop     dword ptr [rax+rax+00000000h]                                  ; +0x68, 0x140120cd8\nmov     edx, ebx                                                       ; +0x70, 0x140120ce0\nmov     rcx, rsi                                                       ; +0x72, 0x140120ce2\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x75, 0x140120ce5\nmov     rcx, rax                                                       ; +0x7b, 0x140120ceb\nmov     rdi, rax                                                       ; +0x7e, 0x140120cee\ncall    GameObject__updateStartPos                                     ; +0x81, 0x140120cf1\nmov     r8, [rdi]                                                      ; +0x86, 0x140120cf6\nlea     rdx, [rsp+98h+var_78]                                          ; +0x89, 0x140120cf9\nmovaps  xmm3, xmm9                                                     ; +0x8e, 0x140120cfe\nmovaps  xmm2, xmm9                                                     ; +0x92, 0x140120d02\nmov     rcx, rdi                                                       ; +0x96, 0x140120d06\ncall    qword ptr [r8+488h]                                            ; +0x99, 0x140120d09\nlea     rcx, [rsp+98h+var_78]                                          ; +0xa0, 0x140120d10\ncall    cs:?getMaxX@CCRect@cocos2d@@QEBAMXZ; cocos2d::CCRect::getMaxX(void) ; +0xa5, 0x140120d15\nlea     rcx, [rsp+98h+var_78]                                          ; +0xab, 0x140120d1b\nmovaps  xmm6, xmm0                                                     ; +0xb0, 0x140120d20\ncall    cs:?getMinX@CCRect@cocos2d@@QEBAMXZ; cocos2d::CCRect::getMinX(void) ; +0xb3, 0x140120d23\ncomiss  xmm7, xmm0                                                     ; +0xb9, 0x140120d29\nmaxss   xmm6, xmm10                                                    ; +0xbc, 0x140120d2c\nmovaps  xmm10, xmm6                                                    ; +0xc1, 0x140120d31\nja      short loc_140120D3F                                            ; +0xc5, 0x140120d35\nucomiss xmm7, xmm8                                                     ; +0xc7, 0x140120d37\njp      short loc_140120D42                                            ; +0xcb, 0x140120d3b\njnz     short loc_140120D42                                            ; +0xcd, 0x140120d3d\nmovaps  xmm7, xmm0                                                     ; +0xcf, 0x140120d3f\nmov     r9b, 1                                                         ; +0xd2, 0x140120d42\nmov     r8d, 15h                                                       ; +0xd5, 0x140120d45\nmov     rdx, rdi                                                       ; +0xdb, 0x140120d4b\nmov     rcx, rbp                                                       ; +0xde, 0x140120d4e\ncall    EditorUI__transformObject                                      ; +0xe1, 0x140120d51\nmov     rcx, rsi                                                       ; +0xe6, 0x140120d56\ninc     ebx                                                            ; +0xe9, 0x140120d59\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xeb, 0x140120d5b\ncmp     ebx, eax                                                       ; +0xf1, 0x140120d61\njb      loc_140120CE0                                                  ; +0xf3, 0x140120d63\nmovaps  xmm9, [rsp+98h+var_58]                                         ; +0xf9, 0x140120d69\nmov     rcx, rsi                                                       ; +0xff, 0x140120d6f\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x102, 0x140120d72\nmovaps  xmm8, [rsp+98h+var_48]                                         ; +0x108, 0x140120d78\ntest    eax, eax                                                       ; +0x10e, 0x140120d7e\njz      loc_140120E28                                                  ; +0x110, 0x140120d80\nnop     word ptr [rax+rax+00000000h]                                   ; +0x116, 0x140120d86\nmov     edx, r14d                                                      ; +0x120, 0x140120d90\nmov     rcx, rsi                                                       ; +0x123, 0x140120d93\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x126, 0x140120d96\nmov     rcx, rax                                                       ; +0x12c, 0x140120d9c\nmov     rdi, rax                                                       ; +0x12f, 0x140120d9f\nmov     rdx, [rax]                                                     ; +0x132, 0x140120da2\ncall    qword ptr [rdx+0C8h]                                           ; +0x135, 0x140120da5\nmov     rdx, [rdi]                                                     ; +0x13b, 0x140120dab\nmovaps  xmm6, xmm10                                                    ; +0x13e, 0x140120dae\nmov     rcx, rdi                                                       ; +0x142, 0x140120db2\nmovss   xmm0, dword ptr [rax]                                          ; +0x145, 0x140120db5\nsubss   xmm0, xmm7                                                     ; +0x149, 0x140120db9\nsubss   xmm6, xmm0                                                     ; +0x14d, 0x140120dbd\ncall    qword ptr [rdx+0C8h]                                           ; +0x151, 0x140120dc1\nmov     rdx, [rdi]                                                     ; +0x157, 0x140120dc7\nmov     rcx, rdi                                                       ; +0x15a, 0x140120dca\nmov     rbx, rax                                                       ; +0x15d, 0x140120dcd\ncall    qword ptr [rdx+0C8h]                                           ; +0x160, 0x140120dd0\nmovaps  xmm1, xmm6                                                     ; +0x166, 0x140120dd6\nlea     rcx, [rsp+98h+arg_18]                                          ; +0x169, 0x140120dd9\nmovss   xmm2, dword ptr [rax+4]                                        ; +0x171, 0x140120de1\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0x176, 0x140120de6\nmov     r8, rbx                                                        ; +0x17c, 0x140120dec\nlea     rdx, [rsp+98h+arg_10]                                          ; +0x17f, 0x140120def\nmov     rcx, rax                                                       ; +0x187, 0x140120df7\ncall    cs:??GCCPoint@cocos2d@@QEBA?AV01@AEBV01@@Z; cocos2d::CCPoint::operator-(cocos2d::CCPoint const &) ; +0x18a, 0x140120dfa\nlea     r8, [rsp+98h+arg_10]                                           ; +0x190, 0x140120e00\nmov     rdx, rdi                                                       ; +0x198, 0x140120e08\nmov     rcx, rbp                                                       ; +0x19b, 0x140120e0b\ncall    EditorUI__moveObject                                           ; +0x19e, 0x140120e0e\nmov     rcx, rsi                                                       ; +0x1a3, 0x140120e13\ninc     r14d                                                           ; +0x1a6, 0x140120e16\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x1a9, 0x140120e19\ncmp     r14d, eax                                                      ; +0x1af, 0x140120e1f\njb      loc_140120D90                                                  ; +0x1b2, 0x140120e22\nmovaps  xmm6, [rsp+98h+var_28]                                         ; +0x1b8, 0x140120e28\nlea     r11, [rsp+98h+var_18]                                          ; +0x1bd, 0x140120e2d\nmov     rbx, [r11+20h]                                                 ; +0x1c5, 0x140120e35\nmov     rbp, [r11+28h]                                                 ; +0x1c9, 0x140120e39\nmovaps  xmm10, xmmword ptr [r11-50h]                                   ; +0x1cd, 0x140120e3d\nmovaps  xmm7, [rsp+98h+var_38]                                         ; +0x1d2, 0x140120e42\nmov     rsp, r11                                                       ; +0x1d7, 0x140120e47\npop     r14                                                            ; +0x1da, 0x140120e4a\npop     rdi                                                            ; +0x1dc, 0x140120e4c\npop     rsi                                                            ; +0x1dd, 0x140120e4d\nretn                                                                   ; +0x1de, 0x140120e4e", "xrefs": ["EditorUI::createSmartObjectsFromTemplate @ 0x14011747b", "EditorUI::transformObjectCall_1 @ 0x1401204f1", "<???> @ 0x140670144", "<???> @ 0x140670178", "<???> @ 0x1406c96b4", "<???> @ 0x1406c96c0"], "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"}