{"type": "func", "start": 4295272448, "end": 4295272616, "name": "EditorUI::getSnapAngle", "pseudocode": "// \n// EditorUI::getSnapAngle from 0x10004a800 to 0x10004a8a8 (168 bytes)\n// \n// 2 xrefs:\n// > EditorUI::transformObjectCall_1 @ 0x10004aa62\n// > EditorUI::transformObjectCall_1 @ 0x10004aab4\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\nfloat __fastcall EditorUI::getSnapAngle(EditorUI *a1, GameObject *a2, cocos2d::CCArray *a3)\n{\n  unsigned int v4; // r15d\n  GameObject *v5; // rax\n  float result; // xmm0_4\n\n  if ( !a3 || !(unsigned int)sub_100720070(a3) )\n  {\n    if ( a2 )\n      return LevelEditorLayer::rotationForSlopeNearObject(a1->m_editorLayer, a2);\n    return -1.0;\n  }\n  if ( !(unsigned int)sub_100720070(a3) )\n    return -1.0;\n  v4 = 0;\n  while ( 1 )\n  {\n    v5 = (GameObject *)sub_1007200C0(a3, v4);\n    result = LevelEditorLayer::rotationForSlopeNearObject(a1->m_editorLayer, v5);\n    if ( result != -1.0 )\n      break;\n    if ( ++v4 >= (unsigned int)sub_100720070(a3) )\n      return -1.0;\n  }\n  return result;\n}", "assembly": "; \n; EditorUI::getSnapAngle from 0x10004a800 to 0x10004a8a8 (168 bytes)\n; \n; 2 xrefs:\n; > EditorUI::transformObjectCall_1 @ 0x10004aa62\n; > EditorUI::transformObjectCall_1 @ 0x10004aab4\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    rbp                                                            ; +0x0, 0x10004a800\nmov     rbp, rsp                                                       ; +0x1, 0x10004a801\npush    r15                                                            ; +0x4, 0x10004a804\npush    r14                                                            ; +0x6, 0x10004a806\npush    rbx                                                            ; +0x8, 0x10004a808\npush    rax                                                            ; +0x9, 0x10004a809\nmov     r15, rsi                                                       ; +0xa, 0x10004a80a\nmov     rbx, rdi                                                       ; +0xd, 0x10004a80d\ntest    rdx, rdx                                                       ; +0x10, 0x10004a810\njz      short loc_10004A877                                            ; +0x13, 0x10004a813\nmov     r14, rdx                                                       ; +0x15, 0x10004a815\nmov     rdi, rdx                                                       ; +0x18, 0x10004a818\ncall    sub_100720070                                                  ; +0x1b, 0x10004a81b\ntest    eax, eax                                                       ; +0x20, 0x10004a820\njz      short loc_10004A877                                            ; +0x22, 0x10004a822\nmov     rdi, r14                                                       ; +0x24, 0x10004a824\ncall    sub_100720070                                                  ; +0x27, 0x10004a827\ntest    eax, eax                                                       ; +0x2c, 0x10004a82c\njz      short loc_10004A895                                            ; +0x2e, 0x10004a82e\nxor     r15d, r15d                                                     ; +0x30, 0x10004a830\nnop     word ptr [rax+rax+00000000h]                                   ; +0x33, 0x10004a833\nmov     rdi, r14                                                       ; +0x40, 0x10004a840\nmov     esi, r15d                                                      ; +0x43, 0x10004a843\ncall    sub_1007200C0                                                  ; +0x46, 0x10004a846\nmov     rdi, [rbx+4E8h]                                                ; +0x4b, 0x10004a84b\nmov     rsi, rax                                                       ; +0x52, 0x10004a852\ncall    LevelEditorLayer__rotationForSlopeNearObject                   ; +0x55, 0x10004a855\nucomiss xmm0, cs:dword_100815094                                       ; +0x5a, 0x10004a85a\njnz     short loc_10004A89D                                            ; +0x61, 0x10004a861\njp      short loc_10004A89D                                            ; +0x63, 0x10004a863\ninc     r15d                                                           ; +0x65, 0x10004a865\nmov     rdi, r14                                                       ; +0x68, 0x10004a868\ncall    sub_100720070                                                  ; +0x6b, 0x10004a86b\ncmp     r15d, eax                                                      ; +0x70, 0x10004a870\njb      short loc_10004A840                                            ; +0x73, 0x10004a873\njmp     short loc_10004A895                                            ; +0x75, 0x10004a875\ntest    r15, r15                                                       ; +0x77, 0x10004a877\njz      short loc_10004A895                                            ; +0x7a, 0x10004a87a\nmov     rdi, [rbx+4E8h]                                                ; +0x7c, 0x10004a87c\nmov     rsi, r15                                                       ; +0x83, 0x10004a883\nadd     rsp, 8                                                         ; +0x86, 0x10004a886\npop     rbx                                                            ; +0x8a, 0x10004a88a\npop     r14                                                            ; +0x8b, 0x10004a88b\npop     r15                                                            ; +0x8d, 0x10004a88d\npop     rbp                                                            ; +0x8f, 0x10004a88f\njmp     LevelEditorLayer__rotationForSlopeNearObject                   ; +0x90, 0x10004a890\nmovss   xmm0, cs:dword_100815094                                       ; +0x95, 0x10004a895\nadd     rsp, 8                                                         ; +0x9d, 0x10004a89d\npop     rbx                                                            ; +0xa1, 0x10004a8a1\npop     r14                                                            ; +0xa2, 0x10004a8a2\npop     r15                                                            ; +0xa4, 0x10004a8a4\npop     rbp                                                            ; +0xa6, 0x10004a8a6\nretn                                                                   ; +0xa7, 0x10004a8a7", "xrefs": ["EditorUI::transformObjectCall_1 @ 0x10004aa62", "EditorUI::transformObjectCall_1 @ 0x10004aab4"], "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"}