{"type": "func", "start": 3675592, "end": 3675682, "name": "EditorUI::xPosFromValue", "pseudocode": "// \n// EditorUI::xPosFromValue from 0x3815c8 to 0x381622 (90 bytes)\n// \n// 1 xrefs:\n// > EditorUI::sliderChanged @ 0x381654\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 EditorUI::xPosFromValue(EditorUI *a1, float a2)\n{\n  float XMin; // s16\n  int SectionCount; // r4\n  float v6; // r0\n\n  XMin = EditorUI::getXMin(a1, 0);\n  SectionCount = LevelEditorLayer::getSectionCount(a1->m_editorLayer);\n  v6 = COERCE_FLOAT(((int (__fastcall *)(cocos2d::CCLayer *))a1->m_editorLayer->m_objectLayer->getScale)(a1->m_editorLayer->m_objectLayer));\n  if ( SectionCount < 100 )\n    SectionCount = 100;\n  return (float)((float)((float)((float)SectionCount * 100.0) * v6) * a2) - XMin;\n}", "assembly": "; \n; EditorUI::xPosFromValue from 0x3815c8 to 0x381622 (90 bytes)\n; \n; 1 xrefs:\n; > EditorUI::sliderChanged @ 0x381654\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            {R3-R5,LR}                                             ; +0x0, 0x3815c8\nMOV             R5, R0                                                 ; +0x2, 0x3815ca\nVPUSH           {D8}                                                   ; +0x4, 0x3815cc\nVMOV            S17, R1                                                ; +0x8, 0x3815d0\nMOVS            R1, #0; int                                            ; +0xc, 0x3815d4\nBL              _ZN8EditorUI7getXMinEi; EditorUI::getXMin(int)         ; +0xe, 0x3815d6\nVMOV            S16, R0                                                ; +0x12, 0x3815da\nLDR.W           R0, [R5,#0x340]; this                                  ; +0x16, 0x3815de\nBL              _ZN16LevelEditorLayer15getSectionCountEv; LevelEditorLayer::getSectionCount(void) ; +0x1a, 0x3815e2\nLDR.W           R3, [R5,#0x340]                                        ; +0x1e, 0x3815e6\nMOV             R4, R0                                                 ; +0x22, 0x3815ea\nLDR.W           R0, [R3,#0x9F0]                                        ; +0x24, 0x3815ec\nLDR             R3, [R0]                                               ; +0x28, 0x3815f0\nLDR             R3, [R3,#0x54]                                         ; +0x2a, 0x3815f2\nBLX             R3                                                     ; +0x2c, 0x3815f4\nCMP             R4, #0x64 ; 'd'                                        ; +0x2e, 0x3815f6\nVLDR            S14, =100.0                                            ; +0x30, 0x3815f8\nIT LT                                                                  ; +0x34, 0x3815fc\nMOVLT           R4, #0x64 ; 'd'                                        ; +0x36, 0x3815fe\nVMOV            S15, R4                                                ; +0x38, 0x381600\nVCVT.F32.S32    S15, S15                                               ; +0x3c, 0x381604\nVMUL.F32        S15, S15, S14                                          ; +0x40, 0x381608\nVMOV            S14, R0                                                ; +0x44, 0x38160c\nVMUL.F32        S15, S15, S14                                          ; +0x48, 0x381610\nVNMLS.F32       S16, S15, S17                                          ; +0x4c, 0x381614\nVMOV            R0, S16                                                ; +0x50, 0x381618\nVPOP            {D8}                                                   ; +0x54, 0x38161c\nPOP             {R3-R5,PC}                                             ; +0x58, 0x381620", "xrefs": ["EditorUI::sliderChanged @ 0x381654"], "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"}