{"type": "func", "start": 5369157808, "end": 5369158207, "name": "OBB2D::create", "pseudocode": "// \n// OBB2D::create from 0x14006d8b0 to 0x14006da3f (399 bytes)\n// \n// 6 xrefs:\n// > GameObject::updateOrientedBox @ 0x1401a1634\n// > GJBaseGameLayer::init @ 0x1402073ff\n// > GJBaseGameLayer::init @ 0x140207435\n// > LevelEditorLayer::init @ 0x1402d277c\n// > <???> @ 0x1406c609c\n// > <???> @ 0x1406c60a8\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=2\nOBB2D *OBB2D::create(cocos2d::CCPoint a1, float a2, float a3, float a4)\n{\n  OBB2D *v5; // rsi\n  const struct cocos2d::CCPoint *v6; // rbx\n  cocos2d::CCPoint v7; // rax\n  OBB2D *v9; // [rsp+30h] [rbp-48h] BYREF\n  cocos2d::CCPoint v10; // [rsp+38h] [rbp-40h] BYREF\n\n  v5 = (OBB2D *)operator new(0x1B8u);\n  v9 = v5;\n  memset(v5, 0, sizeof(OBB2D));\n  cocos2d::CCNode::CCNode(v5);\n  v5->__vftable = (OBB2D_vtbl *)&OBB2D::`vftable';\n  cocos2d::CCPoint::CCPoint(v5->m_corners._Elems);\n  cocos2d::CCPoint::CCPoint(&v5->m_corners._Elems[1]);\n  cocos2d::CCPoint::CCPoint(&v5->m_corners._Elems[2]);\n  cocos2d::CCPoint::CCPoint(&v5->m_corners._Elems[3]);\n  cocos2d::CCPoint::CCPoint(v5->m_positions._Elems);\n  cocos2d::CCPoint::CCPoint(&v5->m_positions._Elems[1]);\n  cocos2d::CCPoint::CCPoint(&v5->m_positions._Elems[2]);\n  cocos2d::CCPoint::CCPoint(&v5->m_positions._Elems[3]);\n  cocos2d::CCPoint::CCPoint(v5->m_edges._Elems);\n  cocos2d::CCPoint::CCPoint(&v5->m_edges._Elems[1]);\n  cocos2d::CCPoint::CCPoint(&v5->m_edges._Elems[2]);\n  cocos2d::CCPoint::CCPoint(&v5->m_edges._Elems[3]);\n  cocos2d::CCPoint::CCPoint(&v5->m_center);\n  v6 = (const struct cocos2d::CCPoint *)cocos2d::CCPoint::CCPoint(\n                                          (cocos2d::CCPoint *)&v9,\n                                          *(const struct cocos2d::CCPoint **)&a1);\n  if ( cocos2d::CCNode::init(v5) )\n  {\n    v7 = (cocos2d::CCPoint)cocos2d::CCPoint::CCPoint(&v10, v6);\n    OBB2D::calculateWithCenter(v5, v7, a2, a3, a4);\n    cocos2d::CCObject::autorelease(v5);\n    return v5;\n  }\n  else\n  {\n    ((void (__fastcall *)(OBB2D *, __int64))v5->~OBB2D)(v5, 1);\n    return nullptr;\n  }\n}", "assembly": "; \n; OBB2D::create from 0x14006d8b0 to 0x14006da3f (399 bytes)\n; \n; 6 xrefs:\n; > GameObject::updateOrientedBox @ 0x1401a1634\n; > GJBaseGameLayer::init @ 0x1402073ff\n; > GJBaseGameLayer::init @ 0x140207435\n; > LevelEditorLayer::init @ 0x1402d277c\n; > <???> @ 0x1406c609c\n; > <???> @ 0x1406c60a8\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, 0x14006d8b0\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x14006d8b5\npush    rdi                                                            ; +0xa, 0x14006d8ba\nsub     rsp, 70h                                                       ; +0xb, 0x14006d8bb\nmovaps  [rsp+78h+var_18], xmm6                                         ; +0xf, 0x14006d8bf\nmovaps  [rsp+78h+var_28], xmm7                                         ; +0x14, 0x14006d8c4\nmovaps  [rsp+78h+var_38], xmm8                                         ; +0x19, 0x14006d8c9\nmovaps  xmm6, xmm3                                                     ; +0x1f, 0x14006d8cf\nmovaps  xmm7, xmm2                                                     ; +0x22, 0x14006d8d2\nmovaps  xmm8, xmm1                                                     ; +0x25, 0x14006d8d5\nmov     rdi, rcx                                                       ; +0x29, 0x14006d8d9\nmov     ecx, 1B8h; Size                                                ; +0x2c, 0x14006d8dc\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x31, 0x14006d8e1\nmov     rsi, rax                                                       ; +0x36, 0x14006d8e6\nmov     [rsp+78h+var_48], rax                                          ; +0x39, 0x14006d8e9\nxor     edx, edx; Val                                                  ; +0x3e, 0x14006d8ee\nmov     r8d, 1B8h; Size                                                ; +0x40, 0x14006d8f0\nmov     rcx, rax; void *                                               ; +0x46, 0x14006d8f6\ncall    memset                                                         ; +0x49, 0x14006d8f9\nmov     rcx, rsi                                                       ; +0x4e, 0x14006d8fe\ncall    cs:??0CCNode@cocos2d@@QEAA@XZ; cocos2d::CCNode::CCNode(void)   ; +0x51, 0x14006d901\nnop                                                                    ; +0x57, 0x14006d907\nlea     rax, ??_7OBB2D@@6B@; const OBB2D::`vftable'                    ; +0x58, 0x14006d908\nmov     [rsi], rax                                                     ; +0x5f, 0x14006d90f\nlea     rcx, [rsi+140h]                                                ; +0x62, 0x14006d912\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x69, 0x14006d919\nlea     rcx, [rsi+148h]                                                ; +0x6f, 0x14006d91f\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x76, 0x14006d926\nlea     rcx, [rsi+150h]                                                ; +0x7c, 0x14006d92c\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x83, 0x14006d933\nlea     rcx, [rsi+158h]                                                ; +0x89, 0x14006d939\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x90, 0x14006d940\nlea     rcx, [rsi+160h]                                                ; +0x96, 0x14006d946\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x9d, 0x14006d94d\nlea     rcx, [rsi+168h]                                                ; +0xa3, 0x14006d953\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xaa, 0x14006d95a\nlea     rcx, [rsi+170h]                                                ; +0xb0, 0x14006d960\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xb7, 0x14006d967\nlea     rcx, [rsi+178h]                                                ; +0xbd, 0x14006d96d\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xc4, 0x14006d974\nlea     rcx, [rsi+180h]                                                ; +0xca, 0x14006d97a\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xd1, 0x14006d981\nlea     rcx, [rsi+188h]                                                ; +0xd7, 0x14006d987\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xde, 0x14006d98e\nlea     rcx, [rsi+190h]                                                ; +0xe4, 0x14006d994\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xeb, 0x14006d99b\nlea     rcx, [rsi+198h]                                                ; +0xf1, 0x14006d9a1\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0xf8, 0x14006d9a8\nlea     rcx, [rsi+1B0h]                                                ; +0xfe, 0x14006d9ae\ncall    cs:??0CCPoint@cocos2d@@QEAA@XZ; cocos2d::CCPoint::CCPoint(void) ; +0x105, 0x14006d9b5\nnop                                                                    ; +0x10b, 0x14006d9bb\nmov     rdx, rdi                                                       ; +0x10c, 0x14006d9bc\nlea     rcx, [rsp+78h+var_48]                                          ; +0x10f, 0x14006d9bf\ncall    cs:??0CCPoint@cocos2d@@QEAA@AEBV01@@Z; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const &) ; +0x114, 0x14006d9c4\nmov     rbx, rax                                                       ; +0x11a, 0x14006d9ca\nmov     rcx, rsi                                                       ; +0x11d, 0x14006d9cd\ncall    cs:__imp_?init@CCNode@cocos2d@@UEAA_NXZ; cocos2d::CCNode::init(void) ; +0x120, 0x14006d9d0\ntest    al, al                                                         ; +0x126, 0x14006d9d6\njz      short loc_14006DA0E                                            ; +0x128, 0x14006d9d8\nmov     rdx, rbx                                                       ; +0x12a, 0x14006d9da\nlea     rcx, [rsp+78h+var_40]                                          ; +0x12d, 0x14006d9dd\ncall    cs:??0CCPoint@cocos2d@@QEAA@AEBV01@@Z; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const &) ; +0x132, 0x14006d9e2\nmov     rdx, rax; int                                                  ; +0x138, 0x14006d9e8\nmovss   [rsp+78h+X], xmm6; X                                           ; +0x13b, 0x14006d9eb\nmovaps  xmm3, xmm7                                                     ; +0x141, 0x14006d9f1\nmovaps  xmm2, xmm8                                                     ; +0x144, 0x14006d9f4\nmov     rcx, rsi; int                                                  ; +0x148, 0x14006d9f8\ncall    OBB2D__calculateWithCenter                                     ; +0x14b, 0x14006d9fb\nmov     rcx, rsi                                                       ; +0x150, 0x14006da00\ncall    cs:?autorelease@CCObject@cocos2d@@QEAAPEAV12@XZ; cocos2d::CCObject::autorelease(void) ; +0x153, 0x14006da03\nmov     rax, rsi                                                       ; +0x159, 0x14006da09\njmp     short loc_14006DA1E                                            ; +0x15c, 0x14006da0c\nmov     rax, [rsi]                                                     ; +0x15e, 0x14006da0e\nmov     edx, 1                                                         ; +0x161, 0x14006da11\nmov     rcx, rsi                                                       ; +0x166, 0x14006da16\ncall    qword ptr [rax+8]                                              ; +0x169, 0x14006da19\nxor     eax, eax                                                       ; +0x16c, 0x14006da1c\nlea     r11, [rsp+78h+var_8]                                           ; +0x16e, 0x14006da1e\nmov     rbx, [r11+10h]                                                 ; +0x173, 0x14006da23\nmov     rsi, [r11+18h]                                                 ; +0x177, 0x14006da27\nmovaps  xmm6, [rsp+78h+var_18]                                         ; +0x17b, 0x14006da2b\nmovaps  xmm7, [rsp+78h+var_28]                                         ; +0x180, 0x14006da30\nmovaps  xmm8, xmmword ptr [r11-30h]                                    ; +0x185, 0x14006da35\nmov     rsp, r11                                                       ; +0x18a, 0x14006da3a\npop     rdi                                                            ; +0x18d, 0x14006da3d\nretn                                                                   ; +0x18e, 0x14006da3e", "xrefs": ["GameObject::updateOrientedBox @ 0x1401a1634", "GJBaseGameLayer::init @ 0x1402073ff", "GJBaseGameLayer::init @ 0x140207435", "LevelEditorLayer::init @ 0x1402d277c", "<???> @ 0x1406c609c", "<???> @ 0x1406c60a8"], "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"}