// // EditorUI::getGridSnappedPos from 0x1003eb9e0 to 0x1003eba54 (116 bytes) // // 9 xrefs: // > SetupSmartBlockLayer::onPasteTemplate @ 0x100070000 // > EditorUI::onCreateObject @ 0x1003eb30c // > EditorUI::doPasteObjects @ 0x1003eed2c // > EditorUI::createPrefab @ 0x1003f22f4 // > EditorUI::applySpecialOffset @ 0x1003f7f58 // > EditorUI::findSnapObject_1 @ 0x1003f8430 // > EditorUI::findSnapObject_1 @ 0x1003f8534 // > EditorUI::ccTouchMoved @ 0x1003f8f5c // > EditorUI::ccTouchEnded @ 0x1003f92b0 // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // // local variable allocation has failed, the output may be wrong! cocos2d::CCPoint __fastcall EditorUI::getGridSnappedPos(EditorUI *a1, cocos2d::CCPoint a2) { float *v2; // x1 int v6; // [xsp+8h] [xbp-18h] BYREF cocos2d::CCPoint LimitedPosition; // 0:kr00_8.8 cocos2d::CCPoint v8; // 0:s0.4,4:s1.4 cocos2d::CCPoint result; // 0:s0.4,4:s1.4 a2.y = a1->m_editorLayer->m_drawGridLayer->m_gridSize; a2.x = a2.y * (float)(floorf(*v2 / a2.y) + 0.5); a2.y = a2.y * (float)(floorf(v2[1] / a2.y) + 0.5); sub_100022980(*(__n128 *)&a2.x, *(__n128 *)&a2.y, &v6); LimitedPosition = EditorUI::getLimitedPosition(a1, v8); result.x = LimitedPosition.x; result.y = LimitedPosition.y; return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source