{"type": "func", "start": 5370491552, "end": 5370491869, "name": "EditorUI::createObject", "pseudocode": "// \n// EditorUI::createObject from 0x1401b32a0 to 0x1401b33dd (317 bytes)\n// \n// 18 xrefs:\n// > EditorUI::onCreateObject @ 0x1401b2ca3\n// > EditorUI::addObjectsToSmartTemplate @ 0x1401b64be\n// > EditorUI::createPrefab @ 0x1401b7615\n// > EditorUI::processSmartObjectsFromType @ 0x1401b7e93\n// > EditorUI::processSmartObjectsFromType @ 0x1401b7f8f\n// > EditorUI::createNewKeyframeAnim @ 0x1401b9237\n// > EditorUI::createLoop @ 0x1401b9651\n// > EditorUI::createLoop @ 0x1401b993d\n// > EditorUI::createGradientFromSelection @ 0x1401b9e20\n// > EditorUI::createEdgeForObject @ 0x1401fa629\n// > EditorUI::createOutlines @ 0x1401fad70\n// > EditorUI::createOutlines @ 0x1401faed3\n// > EditorUI::createRockBases @ 0x1401fb82b\n// > EditorUI::createRockBases @ 0x1401fb9dd\n// > EditorUI::createExtraObject @ 0x1401fea7b\n// > <???> @ 0x1408a1820\n// > <???> @ 0x1408a1830\n// > <???> @ 0x140919ff4\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:27:56 +0000\n// \n\n__int64 __fastcall EditorUI::createObject(__int64 a1, unsigned int a2, const struct cocos2d::CCPoint *a3)\n{\n  __int64 v3; // rbx\n  __int64 v5; // rax\n  __int64 result; // rax\n  __int64 v7; // rbx\n  float v8; // xmm1_4\n  float v9; // xmm0_4\n  __int64 v10; // rax\n  float v11; // xmm1_4\n  float v12; // xmm0_4\n  float v13; // xmm0_4\n  __int64 v14; // rax\n  float v15; // xmm2_4\n  char v16; // [rsp+50h] [rbp+8h] BYREF\n\n  v3 = *(_QWORD *)(a1 + 1512);\n  cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v16, a3);\n  result = LevelEditorLayer::createObject(v3, a2, v5, 0);\n  v7 = result;\n  if ( result )\n  {\n    v8 = *(float *)(result + 1320);\n    if ( v8 != 1.0 || *(float *)(result + 1324) != 1.0 )\n    {\n      v9 = roundf(v8 * 1000.0);\n      *(_DWORD *)(v7 + 64) = 0;\n      v10 = *(_QWORD *)v7;\n      v11 = (float)(int)v9 / 1000.0;\n      *(float *)(v7 + 1160) = v11;\n      *(float *)(v7 + 996) = v11;\n      (*(void (__fastcall **)(__int64))(v10 + 1288))(v7);\n      v12 = *(float *)(v7 + 1324);\n      *(_BYTE *)(v7 + 848) = 1;\n      *(_BYTE *)(v7 + 872) = 1;\n      v13 = roundf(v12 * 1000.0);\n      *(_DWORD *)(v7 + 68) = 0;\n      v14 = *(_QWORD *)v7;\n      v15 = (float)(int)v13 / 1000.0;\n      *(float *)(v7 + 1164) = v15;\n      *(float *)(v7 + 1000) = v15;\n      (*(void (__fastcall **)(__int64))(v14 + 1296))(v7);\n      *(_BYTE *)(v7 + 848) = 1;\n      *(_BYTE *)(v7 + 872) = 1;\n    }\n    return v7;\n  }\n  return result;\n}", "assembly": "; \n; EditorUI::createObject from 0x1401b32a0 to 0x1401b33dd (317 bytes)\n; \n; 18 xrefs:\n; > EditorUI::onCreateObject @ 0x1401b2ca3\n; > EditorUI::addObjectsToSmartTemplate @ 0x1401b64be\n; > EditorUI::createPrefab @ 0x1401b7615\n; > EditorUI::processSmartObjectsFromType @ 0x1401b7e93\n; > EditorUI::processSmartObjectsFromType @ 0x1401b7f8f\n; > EditorUI::createNewKeyframeAnim @ 0x1401b9237\n; > EditorUI::createLoop @ 0x1401b9651\n; > EditorUI::createLoop @ 0x1401b993d\n; > EditorUI::createGradientFromSelection @ 0x1401b9e20\n; > EditorUI::createEdgeForObject @ 0x1401fa629\n; > EditorUI::createOutlines @ 0x1401fad70\n; > EditorUI::createOutlines @ 0x1401faed3\n; > EditorUI::createRockBases @ 0x1401fb82b\n; > EditorUI::createRockBases @ 0x1401fb9dd\n; > EditorUI::createExtraObject @ 0x1401fea7b\n; > <???> @ 0x1408a1820\n; > <???> @ 0x1408a1830\n; > <???> @ 0x140919ff4\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:27:56 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x1401b32a0\npush    rdi                                                            ; +0x5, 0x1401b32a5\nsub     rsp, 40h                                                       ; +0x6, 0x1401b32a6\nmov     rbx, [rcx+5E8h]                                                ; +0xa, 0x1401b32aa\nmov     edi, edx                                                       ; +0x11, 0x1401b32b1\nmov     rdx, r8                                                        ; +0x13, 0x1401b32b3\nlea     rcx, [rsp+48h+arg_0]                                           ; +0x16, 0x1401b32b6\ncall    cs:??0CCPoint@cocos2d@@QEAA@AEBV01@@Z; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const &) ; +0x1b, 0x1401b32bb\nxor     r9d, r9d                                                       ; +0x21, 0x1401b32c1\nmov     edx, edi                                                       ; +0x24, 0x1401b32c4\nmov     r8, rax                                                        ; +0x26, 0x1401b32c6\nmov     rcx, rbx                                                       ; +0x29, 0x1401b32c9\ncall    LevelEditorLayer__createObject                                 ; +0x2c, 0x1401b32cc\nmov     rbx, rax                                                       ; +0x31, 0x1401b32d1\ntest    rax, rax                                                       ; +0x34, 0x1401b32d4\njnz     short loc_1401B32E4                                            ; +0x37, 0x1401b32d7\nmov     rbx, [rsp+48h+arg_8]                                           ; +0x39, 0x1401b32d9\nadd     rsp, 40h                                                       ; +0x3e, 0x1401b32de\npop     rdi                                                            ; +0x42, 0x1401b32e2\nretn                                                                   ; +0x43, 0x1401b32e3\nmovss   xmm1, dword ptr [rax+528h]                                     ; +0x44, 0x1401b32e4\nmovaps  [rsp+48h+var_28], xmm7                                         ; +0x4c, 0x1401b32ec\nmovss   xmm7, cs:flt_140835080                                         ; +0x51, 0x1401b32f1\nucomiss xmm1, xmm7                                                     ; +0x59, 0x1401b32f9\njp      short loc_1401B3313                                            ; +0x5c, 0x1401b32fc\njnz     short loc_1401B3313                                            ; +0x5e, 0x1401b32fe\nmovss   xmm0, dword ptr [rax+52Ch]                                     ; +0x60, 0x1401b3300\nucomiss xmm0, xmm7                                                     ; +0x68, 0x1401b3308\njp      short loc_1401B3313                                            ; +0x6b, 0x1401b330b\njz      loc_1401B33CA                                                  ; +0x6d, 0x1401b330d\nmovaps  [rsp+48h+var_18], xmm6                                         ; +0x73, 0x1401b3313\nmovss   xmm6, cs:dword_140835AA4                                       ; +0x78, 0x1401b3318\nmulss   xmm1, xmm6                                                     ; +0x80, 0x1401b3320\nmovaps  xmm0, xmm1; X                                                  ; +0x84, 0x1401b3324\ncall    cs:__imp_roundf                                                ; +0x87, 0x1401b3327\nmov     rcx, rbx                                                       ; +0x8d, 0x1401b332d\nmov     dword ptr [rbx+40h], 0                                         ; +0x90, 0x1401b3330\ncvttss2si eax, xmm0                                                    ; +0x97, 0x1401b3337\nmovd    xmm1, eax                                                      ; +0x9b, 0x1401b333b\nmov     rax, [rbx]                                                     ; +0x9f, 0x1401b333f\ncvtdq2ps xmm1, xmm1                                                    ; +0xa2, 0x1401b3342\ndivss   xmm1, xmm6                                                     ; +0xa5, 0x1401b3345\nmovss   dword ptr [rbx+488h], xmm1                                     ; +0xa9, 0x1401b3349\nmovss   dword ptr [rbx+3E4h], xmm1                                     ; +0xb1, 0x1401b3351\nmovaps  xmm1, xmm7                                                     ; +0xb9, 0x1401b3359\ncall    qword ptr [rax+508h]                                           ; +0xbc, 0x1401b335c\nmovss   xmm0, dword ptr [rbx+52Ch]                                     ; +0xc2, 0x1401b3362\nmulss   xmm0, xmm6; X                                                  ; +0xca, 0x1401b336a\nmov     byte ptr [rbx+350h], 1                                         ; +0xce, 0x1401b336e\nmov     byte ptr [rbx+368h], 1                                         ; +0xd5, 0x1401b3375\ncall    cs:__imp_roundf                                                ; +0xdc, 0x1401b337c\nmovaps  xmm1, xmm7                                                     ; +0xe2, 0x1401b3382\nmov     dword ptr [rbx+44h], 0                                         ; +0xe5, 0x1401b3385\ncvttss2si eax, xmm0                                                    ; +0xec, 0x1401b338c\nmov     rcx, rbx                                                       ; +0xf0, 0x1401b3390\nmovd    xmm2, eax                                                      ; +0xf3, 0x1401b3393\nmov     rax, [rbx]                                                     ; +0xf7, 0x1401b3397\ncvtdq2ps xmm2, xmm2                                                    ; +0xfa, 0x1401b339a\ndivss   xmm2, xmm6                                                     ; +0xfd, 0x1401b339d\nmovss   dword ptr [rbx+48Ch], xmm2                                     ; +0x101, 0x1401b33a1\nmovss   dword ptr [rbx+3E8h], xmm2                                     ; +0x109, 0x1401b33a9\ncall    qword ptr [rax+510h]                                           ; +0x111, 0x1401b33b1\nmovaps  xmm6, [rsp+48h+var_18]                                         ; +0x117, 0x1401b33b7\nmov     byte ptr [rbx+350h], 1                                         ; +0x11c, 0x1401b33bc\nmov     byte ptr [rbx+368h], 1                                         ; +0x123, 0x1401b33c3\nmovaps  xmm7, [rsp+48h+var_28]                                         ; +0x12a, 0x1401b33ca\nmov     rax, rbx                                                       ; +0x12f, 0x1401b33cf\nmov     rbx, [rsp+48h+arg_8]                                           ; +0x132, 0x1401b33d2\nadd     rsp, 40h                                                       ; +0x137, 0x1401b33d7\npop     rdi                                                            ; +0x13b, 0x1401b33db\nretn                                                                   ; +0x13c, 0x1401b33dc", "xrefs": ["EditorUI::onCreateObject @ 0x1401b2ca3", "EditorUI::addObjectsToSmartTemplate @ 0x1401b64be", "EditorUI::createPrefab @ 0x1401b7615", "EditorUI::processSmartObjectsFromType @ 0x1401b7e93", "EditorUI::processSmartObjectsFromType @ 0x1401b7f8f", "EditorUI::createNewKeyframeAnim @ 0x1401b9237", "EditorUI::createLoop @ 0x1401b9651", "EditorUI::createLoop @ 0x1401b993d", "EditorUI::createGradientFromSelection @ 0x1401b9e20", "EditorUI::createEdgeForObject @ 0x1401fa629", "EditorUI::createOutlines @ 0x1401fad70", "EditorUI::createOutlines @ 0x1401faed3", "EditorUI::createRockBases @ 0x1401fb82b", "EditorUI::createRockBases @ 0x1401fb9dd", "EditorUI::createExtraObject @ 0x1401fea7b", "<???> @ 0x1408a1820", "<???> @ 0x1408a1830", "<???> @ 0x140919ff4"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}