@pinkaphant/kolmo 0.3.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (397) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +36 -36
  3. package/bin/kolmo.mjs +11 -8
  4. package/dist/engine/causewayBridge.d.ts +14 -0
  5. package/dist/engine/causewayBridge.js +166 -0
  6. package/dist/engine/causewayBridge.js.map +1 -0
  7. package/dist/engine/index.d.ts +6 -4
  8. package/dist/engine/index.js +19 -12
  9. package/dist/engine/index.js.map +1 -0
  10. package/dist/engine/islandSettlementMesh.d.ts +26 -0
  11. package/dist/engine/islandSettlementMesh.js +166 -0
  12. package/dist/engine/islandSettlementMesh.js.map +1 -0
  13. package/dist/engine/kolmoActions.d.ts +23 -0
  14. package/dist/engine/kolmoActions.js +164 -0
  15. package/dist/engine/kolmoActions.js.map +1 -0
  16. package/dist/engine/kolmoActor.js +241 -206
  17. package/dist/engine/kolmoActor.js.map +1 -0
  18. package/dist/engine/kolmoFloatingOrigin.d.ts +17 -0
  19. package/dist/engine/kolmoFloatingOrigin.js +98 -0
  20. package/dist/engine/kolmoFloatingOrigin.js.map +1 -0
  21. package/dist/engine/kolmoGame.d.ts +27 -0
  22. package/dist/engine/kolmoGame.js +80 -0
  23. package/dist/engine/kolmoGame.js.map +1 -0
  24. package/dist/engine/kolmoHud.d.ts +23 -0
  25. package/dist/engine/kolmoHud.js +195 -0
  26. package/dist/engine/kolmoHud.js.map +1 -0
  27. package/dist/engine/kolmoInput.d.ts +1 -1
  28. package/dist/engine/kolmoInput.js +57 -30
  29. package/dist/engine/kolmoInput.js.map +1 -0
  30. package/dist/engine/kolmoIsland.d.ts +5 -10
  31. package/dist/engine/kolmoIsland.js +182 -250
  32. package/dist/engine/kolmoIsland.js.map +1 -0
  33. package/dist/engine/kolmoLongDrive.d.ts +3 -4
  34. package/dist/engine/kolmoLongDrive.js +139 -249
  35. package/dist/engine/kolmoLongDrive.js.map +1 -0
  36. package/dist/engine/kolmoPilotMesh.d.ts +2 -0
  37. package/dist/engine/kolmoPilotMesh.js +64 -0
  38. package/dist/engine/kolmoPilotMesh.js.map +1 -0
  39. package/dist/engine/kolmoProcedural.d.ts +13 -0
  40. package/dist/engine/kolmoProcedural.js +101 -0
  41. package/dist/engine/kolmoProcedural.js.map +1 -0
  42. package/dist/engine/kolmoRigs.d.ts +1 -1
  43. package/dist/engine/kolmoRigs.js +88 -47
  44. package/dist/engine/kolmoRigs.js.map +1 -0
  45. package/dist/engine/kolmoStore.d.ts +3 -101
  46. package/dist/engine/kolmoSurface.d.ts +2 -2
  47. package/dist/engine/kolmoSurface.js +150 -134
  48. package/dist/engine/kolmoSurface.js.map +1 -0
  49. package/dist/engine/kolmoTraits.d.ts +128 -0
  50. package/dist/engine/kolmoTraits.js +140 -0
  51. package/dist/engine/kolmoTraits.js.map +1 -0
  52. package/dist/engine/kolmoVehicle.d.ts +3 -33
  53. package/dist/engine/kolmoVehicle.js +66 -253
  54. package/dist/engine/kolmoVehicle.js.map +1 -0
  55. package/dist/engine/kolmoVehicleConfig.d.ts +54 -0
  56. package/dist/engine/kolmoVehicleConfig.js +80 -0
  57. package/dist/engine/kolmoVehicleConfig.js.map +1 -0
  58. package/dist/engine/kolmoVehicleDriver.d.ts +8 -13
  59. package/dist/engine/kolmoVehicleDriver.js +125 -42
  60. package/dist/engine/kolmoVehicleDriver.js.map +1 -0
  61. package/dist/engine/kolmoVehicleInner.d.ts +7 -0
  62. package/dist/engine/kolmoVehicleInner.js +261 -0
  63. package/dist/engine/kolmoVehicleInner.js.map +1 -0
  64. package/dist/engine/kolmoWorld.d.ts +6 -4
  65. package/dist/engine/kolmoWorld.js +134 -136
  66. package/dist/engine/kolmoWorld.js.map +1 -0
  67. package/dist/engine/longDriveKit.d.ts +5 -12
  68. package/dist/engine/longDriveKit.js +121 -233
  69. package/dist/engine/longDriveKit.js.map +1 -0
  70. package/dist/engine/longDriveRoadside.d.ts +16 -0
  71. package/dist/engine/longDriveRoadside.js +171 -0
  72. package/dist/engine/longDriveRoadside.js.map +1 -0
  73. package/dist/engine/macroCellBuilder.d.ts +34 -0
  74. package/dist/engine/macroCellBuilder.js +145 -0
  75. package/dist/engine/macroCellBuilder.js.map +1 -0
  76. package/dist/engine/mainlandMacroCell.d.ts +2 -2
  77. package/dist/engine/mainlandMacroCell.js +77 -165
  78. package/dist/engine/mainlandMacroCell.js.map +1 -0
  79. package/dist/engine/shiftedFixedBody.d.ts +1 -1
  80. package/dist/engine/shiftedFixedBody.js +55 -28
  81. package/dist/engine/shiftedFixedBody.js.map +1 -0
  82. package/dist/importer/ChopShopPanel.d.ts +10 -32
  83. package/dist/importer/ChopShopPanel.js +320 -470
  84. package/dist/importer/ChopShopPanel.js.map +1 -0
  85. package/dist/importer/DomainWorkshopPanel.d.ts +2 -1
  86. package/dist/importer/DomainWorkshopPanel.js +172 -242
  87. package/dist/importer/DomainWorkshopPanel.js.map +1 -0
  88. package/dist/importer/GateHudBar.d.ts +8 -3
  89. package/dist/importer/GateHudBar.js +289 -284
  90. package/dist/importer/GateHudBar.js.map +1 -0
  91. package/dist/importer/GlbImportGate.d.ts +2 -1
  92. package/dist/importer/GlbImportGate.js +254 -262
  93. package/dist/importer/GlbImportGate.js.map +1 -0
  94. package/dist/importer/ImperativeVehicleRig.d.ts +2 -2
  95. package/dist/importer/ImperativeVehicleRig.js +223 -284
  96. package/dist/importer/ImperativeVehicleRig.js.map +1 -0
  97. package/dist/importer/LiveDrivePads.d.ts +20 -0
  98. package/dist/importer/LiveDrivePads.js +169 -0
  99. package/dist/importer/LiveDrivePads.js.map +1 -0
  100. package/dist/importer/PaperShellDebrisRig.d.ts +25 -0
  101. package/dist/importer/PaperShellDebrisRig.js +143 -0
  102. package/dist/importer/PaperShellDebrisRig.js.map +1 -0
  103. package/dist/importer/R2VaultDrawer.d.ts +12 -0
  104. package/dist/importer/R2VaultDrawer.js +90 -0
  105. package/dist/importer/R2VaultDrawer.js.map +1 -0
  106. package/dist/importer/Step1CalibrationPlinth.d.ts +23 -15
  107. package/dist/importer/Step1CalibrationPlinth.js +180 -313
  108. package/dist/importer/Step1CalibrationPlinth.js.map +1 -0
  109. package/dist/importer/Step1ExplodedIslands.d.ts +31 -0
  110. package/dist/importer/Step1ExplodedIslands.js +144 -0
  111. package/dist/importer/Step1ExplodedIslands.js.map +1 -0
  112. package/dist/importer/Step2UniversalPad.d.ts +7 -14
  113. package/dist/importer/Step2UniversalPad.js +54 -197
  114. package/dist/importer/Step2UniversalPad.js.map +1 -0
  115. package/dist/importer/VfxEmitterPool.js +59 -86
  116. package/dist/importer/VfxEmitterPool.js.map +1 -0
  117. package/dist/importer/WheelRingHandles3D.d.ts +11 -0
  118. package/dist/importer/WheelRingHandles3D.js +318 -0
  119. package/dist/importer/WheelRingHandles3D.js.map +1 -0
  120. package/dist/importer/archLinerGeom.d.ts +2 -0
  121. package/dist/importer/archLinerGeom.js +51 -0
  122. package/dist/importer/archLinerGeom.js.map +1 -0
  123. package/dist/importer/{vehiclePanelAnim.d.ts → chopHingeHelpers.d.ts} +0 -10
  124. package/dist/importer/chopHingeHelpers.js +193 -0
  125. package/dist/importer/chopHingeHelpers.js.map +1 -0
  126. package/dist/importer/chopShopActions.d.ts +20 -32
  127. package/dist/importer/chopShopActions.js +142 -238
  128. package/dist/importer/chopShopActions.js.map +1 -0
  129. package/dist/importer/chopShopHandlers.d.ts +26 -0
  130. package/dist/importer/chopShopHandlers.js +276 -0
  131. package/dist/importer/chopShopHandlers.js.map +1 -0
  132. package/dist/importer/chopShopIoActions.d.ts +18 -0
  133. package/dist/importer/chopShopIoActions.js +161 -0
  134. package/dist/importer/chopShopIoActions.js.map +1 -0
  135. package/dist/importer/chopShopMcpAction.d.ts +18 -0
  136. package/dist/importer/chopShopMcpAction.js +58 -0
  137. package/dist/importer/chopShopMcpAction.js.map +1 -0
  138. package/dist/importer/cylinderBooleanSlice.d.ts +14 -0
  139. package/dist/importer/cylinderBooleanSlice.js +110 -0
  140. package/dist/importer/cylinderBooleanSlice.js.map +1 -0
  141. package/dist/importer/cylinderSliceMath.d.ts +14 -0
  142. package/dist/importer/cylinderSliceMath.js +251 -0
  143. package/dist/importer/cylinderSliceMath.js.map +1 -0
  144. package/dist/importer/fusedWheelDetect.d.ts +4 -0
  145. package/dist/importer/fusedWheelDetect.js +176 -0
  146. package/dist/importer/fusedWheelDetect.js.map +1 -0
  147. package/dist/importer/fusedWheelFit.d.ts +13 -0
  148. package/dist/importer/fusedWheelFit.js +138 -0
  149. package/dist/importer/fusedWheelFit.js.map +1 -0
  150. package/dist/importer/gateStore.d.ts +3 -6
  151. package/dist/importer/gateStore.js +36 -30
  152. package/dist/importer/gateStore.js.map +1 -0
  153. package/dist/importer/glbNormalizer.d.ts +1 -10
  154. package/dist/importer/glbNormalizer.js +120 -146
  155. package/dist/importer/glbNormalizer.js.map +1 -0
  156. package/dist/importer/importerWebMcp.d.ts +4 -3
  157. package/dist/importer/importerWebMcp.js +41 -339
  158. package/dist/importer/importerWebMcp.js.map +1 -0
  159. package/dist/importer/importerWebMcpTools.d.ts +2 -0
  160. package/dist/importer/importerWebMcpTools.js +340 -0
  161. package/dist/importer/importerWebMcpTools.js.map +1 -0
  162. package/dist/importer/index.d.ts +6 -4
  163. package/dist/importer/index.js +32 -25
  164. package/dist/importer/index.js.map +1 -0
  165. package/dist/importer/khrCarPlanHelpers.d.ts +39 -0
  166. package/dist/importer/khrCarPlanHelpers.js +310 -0
  167. package/dist/importer/khrCarPlanHelpers.js.map +1 -0
  168. package/dist/importer/khrCarPlanner.d.ts +8 -0
  169. package/dist/importer/khrCarPlanner.js +315 -0
  170. package/dist/importer/khrCarPlanner.js.map +1 -0
  171. package/dist/importer/khrCompiler.d.ts +4 -41
  172. package/dist/importer/khrCompiler.js +79 -673
  173. package/dist/importer/khrCompiler.js.map +1 -0
  174. package/dist/importer/khrCraftPropCompiler.d.ts +45 -0
  175. package/dist/importer/khrCraftPropCompiler.js +263 -0
  176. package/dist/importer/khrCraftPropCompiler.js.map +1 -0
  177. package/dist/importer/khrNodeNameGuard.d.ts +20 -0
  178. package/dist/importer/khrNodeNameGuard.js +139 -0
  179. package/dist/importer/khrNodeNameGuard.js.map +1 -0
  180. package/dist/importer/launcherBake.js +99 -39
  181. package/dist/importer/launcherBake.js.map +1 -0
  182. package/dist/importer/meshIslands.d.ts +4 -50
  183. package/dist/importer/meshIslands.js +84 -288
  184. package/dist/importer/meshIslands.js.map +1 -0
  185. package/dist/importer/meshSliceBuffers.d.ts +15 -0
  186. package/dist/importer/meshSliceBuffers.js +159 -0
  187. package/dist/importer/meshSliceBuffers.js.map +1 -0
  188. package/dist/importer/polygonEarClipYZ.d.ts +3 -0
  189. package/dist/importer/polygonEarClipYZ.js +67 -0
  190. package/dist/importer/polygonEarClipYZ.js.map +1 -0
  191. package/dist/importer/sceneSiNormalize.d.ts +19 -0
  192. package/dist/importer/sceneSiNormalize.js +145 -0
  193. package/dist/importer/sceneSiNormalize.js.map +1 -0
  194. package/dist/importer/starterScene.d.ts +3 -0
  195. package/dist/importer/starterScene.js +76 -0
  196. package/dist/importer/starterScene.js.map +1 -0
  197. package/dist/importer/surfaceCutter.d.ts +5 -25
  198. package/dist/importer/surfaceCutter.js +70 -334
  199. package/dist/importer/surfaceCutter.js.map +1 -0
  200. package/dist/importer/surfaceGeodesic.d.ts +7 -0
  201. package/dist/importer/surfaceGeodesic.js +130 -0
  202. package/dist/importer/surfaceGeodesic.js.map +1 -0
  203. package/dist/importer/surfaceLoopRefine.d.ts +6 -0
  204. package/dist/importer/surfaceLoopRefine.js +171 -0
  205. package/dist/importer/surfaceLoopRefine.js.map +1 -0
  206. package/dist/importer/surfacePeel.d.ts +11 -0
  207. package/dist/importer/surfacePeel.js +119 -0
  208. package/dist/importer/surfacePeel.js.map +1 -0
  209. package/dist/importer/surfaceTopology.d.ts +4 -19
  210. package/dist/importer/surfaceTopology.js +92 -160
  211. package/dist/importer/surfaceTopology.js.map +1 -0
  212. package/dist/importer/universalGateBake.d.ts +7 -9
  213. package/dist/importer/universalGateBake.js +117 -109
  214. package/dist/importer/universalGateBake.js.map +1 -0
  215. package/dist/importer/usdPhysicsSpecs.d.ts +3 -0
  216. package/dist/importer/usdPhysicsSpecs.js +245 -0
  217. package/dist/importer/usdPhysicsSpecs.js.map +1 -0
  218. package/dist/importer/usdTextParse.d.ts +12 -0
  219. package/dist/importer/usdTextParse.js +118 -0
  220. package/dist/importer/usdTextParse.js.map +1 -0
  221. package/dist/importer/usdToGlb.d.ts +3 -2
  222. package/dist/importer/usdToGlb.js +80 -292
  223. package/dist/importer/usdToGlb.js.map +1 -0
  224. package/dist/importer/useChopShopController.d.ts +51 -74
  225. package/dist/importer/useChopShopController.js +161 -453
  226. package/dist/importer/useChopShopController.js.map +1 -0
  227. package/dist/importer/useChopShopState.d.ts +103 -0
  228. package/dist/importer/useChopShopState.js +324 -0
  229. package/dist/importer/useChopShopState.js.map +1 -0
  230. package/dist/importer/useWasdKeyRef.d.ts +9 -0
  231. package/dist/importer/useWasdKeyRef.js +35 -0
  232. package/dist/importer/useWasdKeyRef.js.map +1 -0
  233. package/dist/importer/vehiclePartSplit.d.ts +33 -0
  234. package/dist/importer/vehiclePartSplit.js +183 -0
  235. package/dist/importer/vehiclePartSplit.js.map +1 -0
  236. package/dist/importer/wheelAxlePairing.d.ts +4 -3
  237. package/dist/importer/wheelAxlePairing.js +128 -122
  238. package/dist/importer/wheelAxlePairing.js.map +1 -0
  239. package/dist/importer/wheelCutterHelpers.d.ts +42 -0
  240. package/dist/importer/wheelCutterHelpers.js +178 -0
  241. package/dist/importer/wheelCutterHelpers.js.map +1 -0
  242. package/dist/importer/wheelRingHandleMath.d.ts +20 -0
  243. package/dist/importer/wheelRingHandleMath.js +66 -0
  244. package/dist/importer/wheelRingHandleMath.js.map +1 -0
  245. package/dist/index.d.ts +3 -2
  246. package/dist/index.js +90 -69
  247. package/dist/index.js.map +1 -0
  248. package/dist/junk/DestructibleTarget.d.ts +3 -3
  249. package/dist/junk/DestructibleTarget.js +177 -114
  250. package/dist/junk/DestructibleTarget.js.map +1 -0
  251. package/dist/junk/KolmoJunk.js +55 -44
  252. package/dist/junk/KolmoJunk.js.map +1 -0
  253. package/dist/junk/ShardPieces.d.ts +2 -1
  254. package/dist/junk/ShardPieces.js +80 -61
  255. package/dist/junk/ShardPieces.js.map +1 -0
  256. package/dist/junk/TargetDecals.d.ts +6 -15
  257. package/dist/junk/TargetDecals.js +66 -40
  258. package/dist/junk/TargetDecals.js.map +1 -0
  259. package/dist/junk/bvhShatter.d.ts +2 -6
  260. package/dist/junk/bvhShatter.js +89 -43
  261. package/dist/junk/bvhShatter.js.map +1 -0
  262. package/dist/junk/bvhTriCollector.d.ts +2 -6
  263. package/dist/junk/bvhTriCollector.js +111 -62
  264. package/dist/junk/bvhTriCollector.js.map +1 -0
  265. package/dist/junk/index.d.ts +2 -2
  266. package/dist/junk/index.js +11 -11
  267. package/dist/junk/index.js.map +1 -0
  268. package/dist/junk/junkGeometry.d.ts +5 -26
  269. package/dist/junk/junkGeometry.js +61 -43
  270. package/dist/junk/junkGeometry.js.map +1 -0
  271. package/dist/junk/junkImportSanitize.d.ts +4 -5
  272. package/dist/junk/junkImportSanitize.js +57 -37
  273. package/dist/junk/junkImportSanitize.js.map +1 -0
  274. package/dist/junk/junkImporter.d.ts +2 -13
  275. package/dist/junk/junkImporter.js +105 -76
  276. package/dist/junk/junkImporter.js.map +1 -0
  277. package/dist/junk/junkLabelCanvas.d.ts +1 -6
  278. package/dist/junk/junkLabelCanvas.js +147 -29
  279. package/dist/junk/junkLabelCanvas.js.map +1 -0
  280. package/dist/junk/junkLabels.d.ts +4 -26
  281. package/dist/junk/junkLabels.js +42 -28
  282. package/dist/junk/junkLabels.js.map +1 -0
  283. package/dist/junk/targetHelpers.d.ts +3 -4
  284. package/dist/junk/targetHelpers.js +121 -67
  285. package/dist/junk/targetHelpers.js.map +1 -0
  286. package/dist/junk/targetHitLogic.d.ts +8 -8
  287. package/dist/junk/targetHitLogic.js +131 -95
  288. package/dist/junk/targetHitLogic.js.map +1 -0
  289. package/dist/junk/useTargetAssets.d.ts +9 -14
  290. package/dist/junk/useTargetAssets.js +113 -85
  291. package/dist/junk/useTargetAssets.js.map +1 -0
  292. package/dist/physics/index.d.ts +1 -8
  293. package/dist/physics/index.js +80 -85
  294. package/dist/physics/index.js.map +1 -0
  295. package/dist/schema/kolmoSchema.d.ts +3 -64
  296. package/dist/schema/kolmoSchema.js +75 -149
  297. package/dist/schema/kolmoSchema.js.map +1 -0
  298. package/dist/schema/kolmoStamp.d.ts +11 -0
  299. package/dist/schema/kolmoStamp.js +119 -0
  300. package/dist/schema/kolmoStamp.js.map +1 -0
  301. package/dist/schema/kolmoTypes.d.ts +63 -0
  302. package/dist/schema/kolmoTypes.js +66 -0
  303. package/dist/schema/kolmoTypes.js.map +1 -0
  304. package/dist/shaders/celestialBackdrop.d.ts +2 -10
  305. package/dist/shaders/celestialBackdrop.js +128 -291
  306. package/dist/shaders/celestialBackdrop.js.map +1 -0
  307. package/dist/shaders/emitterShaders.d.ts +9 -0
  308. package/dist/shaders/emitterShaders.js +114 -0
  309. package/dist/shaders/emitterShaders.js.map +1 -0
  310. package/dist/shaders/index.d.ts +1 -1
  311. package/dist/shaders/index.js +12 -9
  312. package/dist/shaders/index.js.map +1 -0
  313. package/dist/shaders/plumeAndSparkle.d.ts +2 -4
  314. package/dist/shaders/plumeAndSparkle.js +152 -191
  315. package/dist/shaders/plumeAndSparkle.js.map +1 -0
  316. package/dist/shaders/ps2GlslShared.js +29 -2
  317. package/dist/shaders/ps2GlslShared.js.map +1 -0
  318. package/dist/shaders/ps2MaterialsTSL.js +132 -51
  319. package/dist/shaders/ps2MaterialsTSL.js.map +1 -0
  320. package/dist/shaders/ps2MaterialsWebGL.js +45 -28
  321. package/dist/shaders/ps2MaterialsWebGL.js.map +1 -0
  322. package/dist/shaders/ps2RoadWebGL.js +69 -32
  323. package/dist/shaders/ps2RoadWebGL.js.map +1 -0
  324. package/dist/shaders/ps2TerrainWebGL.js +107 -30
  325. package/dist/shaders/ps2TerrainWebGL.js.map +1 -0
  326. package/dist/shaders/ps2Textures.d.ts +1 -1
  327. package/dist/shaders/ps2Textures.js +116 -41
  328. package/dist/shaders/ps2Textures.js.map +1 -0
  329. package/dist/shaders/retroPalettes.d.ts +1 -1
  330. package/dist/shaders/retroPalettes.js +90 -57
  331. package/dist/shaders/retroPalettes.js.map +1 -0
  332. package/dist/shaders/retroShader.d.ts +2 -86
  333. package/dist/shaders/retroShader.js +65 -196
  334. package/dist/shaders/retroShader.js.map +1 -0
  335. package/dist/shaders/retroUniforms.d.ts +60 -0
  336. package/dist/shaders/retroUniforms.js +215 -0
  337. package/dist/shaders/retroUniforms.js.map +1 -0
  338. package/dist/shaders/skyboxShaders.d.ts +16 -0
  339. package/dist/shaders/skyboxShaders.js +266 -0
  340. package/dist/shaders/skyboxShaders.js.map +1 -0
  341. package/dist/shaders/tsl.d.ts +1 -1
  342. package/dist/shaders/tsl.js.map +1 -0
  343. package/dist/vite/index.d.ts +1 -1
  344. package/dist/vite/index.js +38 -32
  345. package/dist/vite/index.js.map +1 -0
  346. package/dist/world/frontage.js +25 -21
  347. package/dist/world/frontage.js.map +1 -0
  348. package/dist/world/index.d.ts +4 -4
  349. package/dist/world/index.js +12 -11
  350. package/dist/world/index.js.map +1 -0
  351. package/dist/world/infiniteWorld2D.d.ts +0 -5
  352. package/dist/world/infiniteWorld2D.js +175 -200
  353. package/dist/world/infiniteWorld2D.js.map +1 -0
  354. package/dist/world/island.js +81 -166
  355. package/dist/world/island.js.map +1 -0
  356. package/dist/world/islandPathing.d.ts +6 -0
  357. package/dist/world/islandPathing.js +166 -0
  358. package/dist/world/islandPathing.js.map +1 -0
  359. package/dist/world/macroCellSchema.js +15 -8
  360. package/dist/world/macroCellSchema.js.map +1 -0
  361. package/dist/world/macroKnightAStar.js +140 -71
  362. package/dist/world/macroKnightAStar.js.map +1 -0
  363. package/dist/world/macroSettlementZones.d.ts +9 -0
  364. package/dist/world/macroSettlementZones.js +108 -0
  365. package/dist/world/macroSettlementZones.js.map +1 -0
  366. package/dist/world/random.js +50 -24
  367. package/dist/world/random.js.map +1 -0
  368. package/dist/world/road.js +152 -90
  369. package/dist/world/road.js.map +1 -0
  370. package/dist/world/roadRibbon.d.ts +4 -19
  371. package/dist/world/roadRibbon.js +129 -124
  372. package/dist/world/roadRibbon.js.map +1 -0
  373. package/dist/world/terrain.d.ts +1 -1
  374. package/dist/world/terrain.js +111 -65
  375. package/dist/world/terrain.js.map +1 -0
  376. package/dist/world/terrainGeometry.d.ts +14 -0
  377. package/dist/world/terrainGeometry.js +76 -0
  378. package/dist/world/terrainGeometry.js.map +1 -0
  379. package/dist/world/worldTypes.d.ts +3 -3
  380. package/dist/world/worldTypes.js +133 -67
  381. package/dist/world/worldTypes.js.map +1 -0
  382. package/docs/api-reference.md +190 -0
  383. package/package.json +54 -34
  384. package/dist/engine/kolmoStore.js +0 -247
  385. package/dist/importer/CabinPreviewRig.d.ts +0 -13
  386. package/dist/importer/CabinPreviewRig.js +0 -138
  387. package/dist/importer/CabinStepSection.d.ts +0 -17
  388. package/dist/importer/CabinStepSection.js +0 -222
  389. package/dist/importer/ImporterPlinthUikitTags.d.ts +0 -20
  390. package/dist/importer/ImporterPlinthUikitTags.js +0 -119
  391. package/dist/importer/cabinMeshBuilders.d.ts +0 -13
  392. package/dist/importer/cabinMeshBuilders.js +0 -104
  393. package/dist/importer/cabinMixamoRig.d.ts +0 -53
  394. package/dist/importer/cabinMixamoRig.js +0 -150
  395. package/dist/importer/chopShopUiComponents.d.ts +0 -22
  396. package/dist/importer/chopShopUiComponents.js +0 -91
  397. package/dist/importer/vehiclePanelAnim.js +0 -214
@@ -1,559 +1,409 @@
1
- import { CabinStepSection as e } from "./CabinStepSection.js";
2
- import { PillBtn as t, S_PANEL as n, S_SEC as r, S_SEL as i, SliderRow as a } from "./chopShopUiComponents.js";
3
- import { STEER_CURVE_IDS as o, TIRE_PRESET_IDS as s, TORQUE_CURVE_IDS as c } from "./khrCompiler.js";
4
- import { CHOP_ROLES as l } from "./surfaceTopology.js";
5
- import { useState as u } from "react";
6
- import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
1
+ import { CHOP_ROLES } from "./surfaceTopology.js";
2
+ import "react";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
7
4
  // src/importer/ChopShopPanel.tsx
8
- var m = [
9
- {
10
- id: "fit",
11
- label: "1·Fit"
12
- },
13
- {
14
- id: "shell",
15
- label: "2·Shell"
16
- },
17
- {
18
- id: "cabin",
19
- label: "3·Cabin"
20
- },
21
- {
22
- id: "drive",
23
- label: "4·Drive"
24
- }
25
- ], h = [
26
- "wheel",
27
- "door",
28
- "hood",
29
- "trunk",
30
- "glass"
31
- ], g = [
32
- "fender",
33
- "bumper",
34
- "propeller"
35
- ], _ = [
5
+ var asideStyle = {
6
+ position: "absolute",
7
+ top: 64,
8
+ right: 12,
9
+ bottom: 60,
10
+ width: "min(264px, calc(100% - 24px))",
11
+ boxSizing: "border-box",
12
+ display: "flex",
13
+ flexDirection: "column",
14
+ gap: 10,
15
+ padding: 12,
16
+ background: "rgba(10, 13, 18, 0.86)",
17
+ border: "1px solid rgba(255,255,255,0.1)",
18
+ borderRadius: 10,
19
+ fontFamily: "Inter, ui-sans-serif, system-ui, sans-serif",
20
+ fontSize: 12,
21
+ color: "#E6EDF3",
22
+ overflowY: "auto",
23
+ zIndex: 18,
24
+ backdropFilter: "blur(8px)"
25
+ };
26
+ var inlineAsideStyle = {
27
+ ...asideStyle,
28
+ position: "relative",
29
+ top: "auto",
30
+ right: "auto",
31
+ bottom: "auto",
32
+ width: "min(264px, 100%)",
33
+ maxHeight: "100%",
34
+ marginLeft: "auto",
35
+ alignSelf: "flex-start",
36
+ pointerEvents: "auto"
37
+ };
38
+ function Btn({ label, active = false, disabled = false, accent = "#00E5FF", onClick }) {
39
+ return /* @__PURE__ */ jsx("button", {
40
+ type: "button",
41
+ disabled,
42
+ onClick,
43
+ style: {
44
+ padding: "6px 9px",
45
+ borderRadius: 6,
46
+ fontSize: 11.5,
47
+ fontWeight: active ? 600 : 500,
48
+ fontFamily: "inherit",
49
+ cursor: disabled ? "not-allowed" : "pointer",
50
+ border: `1px solid ${disabled ? "rgba(255,255,255,0.08)" : active ? accent : "rgba(255,255,255,0.14)"}`,
51
+ background: active ? accent : "rgba(255,255,255,0.04)",
52
+ color: disabled ? "#64748B" : active ? "#07090C" : "#E2E8F0"
53
+ },
54
+ children: label
55
+ });
56
+ }
57
+ var MODES = [
36
58
  {
37
59
  mode: "island",
38
- label: "Click Piece",
39
- hint: "1-click a whole wheel, door, or window mesh."
60
+ label: "Island"
40
61
  },
41
62
  {
42
63
  mode: "crease",
43
- label: "Smart Panel",
44
- hint: "Click once to grab up to panel shutlines, then Peel."
64
+ label: "Crease"
45
65
  },
46
66
  {
47
67
  mode: "loop",
48
- label: "Trace Seam",
49
- hint: "Click 3+ dots around a door/window, Close Loop, then Peel."
68
+ label: "Loop"
50
69
  },
51
70
  {
52
71
  mode: "triangle",
53
- label: "Paint Brush",
54
- hint: "Drag to paint faces across meshes. Right-click/Alt erases."
72
+ label: "Brush"
55
73
  }
56
74
  ];
57
- function v(v) {
58
- let [y, b] = u(!1), x = l.find((e) => e.role === v.activeRole) ?? l[0], S = v.vehicleArchetype === "starcraft", C = (e) => e === "wheel" ? v.wheelCount : e === "propeller" ? v.propellerCount : Object.values(v.partPicks).filter((t) => t === e).length, w = Object.keys(v.partPicks).length;
59
- return /* @__PURE__ */ p("aside", {
60
- style: n,
61
- "aria-label": "Vehicle Chop-Shop",
75
+ function ChopShopPanel(p) {
76
+ const cuttersReady = (p.wheelCutterCount ?? 0) > 0;
77
+ const totalPicked = Object.keys(p.partPicks).length;
78
+ return /* @__PURE__ */ jsxs("aside", {
79
+ style: p.inline ? inlineAsideStyle : asideStyle,
80
+ "aria-label": "Vehicle Calibration",
62
81
  children: [
63
- /* @__PURE__ */ p("div", {
82
+ /* @__PURE__ */ jsxs("div", {
64
83
  style: {
65
84
  display: "flex",
66
85
  justifyContent: "space-between",
67
86
  alignItems: "center"
68
87
  },
69
- children: [/* @__PURE__ */ f("span", {
88
+ children: [/* @__PURE__ */ jsx("span", {
70
89
  style: {
71
- fontSize: 11.5,
72
- fontWeight: 800,
73
- color: "#FFB000",
74
- letterSpacing: "0.05em"
90
+ fontWeight: 600,
91
+ fontSize: 13
75
92
  },
76
- children: "CAR CHOP-SHOP"
77
- }), /* @__PURE__ */ f("span", {
93
+ children: "Vehicle Calibration"
94
+ }), /* @__PURE__ */ jsx("span", {
78
95
  style: {
79
- fontSize: 10,
96
+ fontSize: 11,
80
97
  color: "#38BDF8"
81
98
  },
82
- children: `${v.wheelCount}W · ${w}P · ${v.cabin.enabled ? "SEAT ✓" : "NO SEAT"}`
99
+ children: `${p.wheelCount} wheels`
83
100
  })]
84
101
  }),
85
- /* @__PURE__ */ f("div", {
102
+ /* @__PURE__ */ jsxs("label", {
86
103
  style: {
87
104
  display: "grid",
88
- gridTemplateColumns: "repeat(4, 1fr)",
89
- gap: 4
105
+ gap: 4,
106
+ fontSize: 11.5,
107
+ color: "#94A3B8"
90
108
  },
91
- children: m.map((e) => /* @__PURE__ */ f(t, {
92
- label: e.label,
93
- active: v.wizardTab === e.id,
94
- color: "#00E5FF",
95
- center: !0,
96
- onClick: () => v.onChangeWizardTab(e.id)
97
- }, e.id))
109
+ children: [/* @__PURE__ */ jsxs("div", {
110
+ style: {
111
+ display: "flex",
112
+ justifyContent: "space-between"
113
+ },
114
+ children: [/* @__PURE__ */ jsx("span", { children: "Target Length" }), /* @__PURE__ */ jsx("span", {
115
+ style: { color: "#E6EDF3" },
116
+ children: `${p.targetMeters.toFixed(2)} m`
117
+ })]
118
+ }), /* @__PURE__ */ jsx("input", {
119
+ type: "range",
120
+ min: 1.6,
121
+ max: 7.5,
122
+ step: .05,
123
+ value: p.targetMeters,
124
+ onChange: (e) => p.onChangeTargetMeters(Number(e.target.value)),
125
+ style: {
126
+ width: "100%",
127
+ accentColor: "#00E5FF"
128
+ }
129
+ })]
98
130
  }),
99
- v.wizardTab === "fit" && /* @__PURE__ */ p("div", {
100
- style: r,
131
+ /* @__PURE__ */ jsxs("div", {
132
+ style: {
133
+ display: "grid",
134
+ gap: 6,
135
+ paddingTop: 6,
136
+ borderTop: "1px solid rgba(255,255,255,0.08)"
137
+ },
101
138
  children: [
102
- /* @__PURE__ */ f("div", {
139
+ /* @__PURE__ */ jsx("span", {
103
140
  style: {
104
- fontSize: 10,
105
- color: "#94A3B8",
106
- lineHeight: 1.35
141
+ fontSize: 11,
142
+ color: "#94A3B8"
107
143
  },
108
- children: "Point nose toward the cyan +Z arrow and set real-world length."
144
+ children: "Wheel Coring & 3D Rings"
109
145
  }),
110
- /* @__PURE__ */ p("div", {
146
+ /* @__PURE__ */ jsxs("label", {
111
147
  style: {
112
- display: "grid",
113
- gridTemplateColumns: "repeat(3, 1fr)",
114
- gap: 4
148
+ display: "flex",
149
+ alignItems: "center",
150
+ gap: 7,
151
+ cursor: "pointer"
115
152
  },
116
- children: [
117
- /* @__PURE__ */ f(t, {
118
- label: "Turn X 90°",
119
- center: !0,
120
- onClick: () => v.onBumpTurn(0)
121
- }),
122
- /* @__PURE__ */ f(t, {
123
- label: "Turn Y 90°",
124
- center: !0,
125
- onClick: () => v.onBumpTurn(1)
126
- }),
127
- /* @__PURE__ */ f(t, {
128
- label: "Turn Z 90°",
129
- center: !0,
130
- onClick: () => v.onBumpTurn(2)
131
- })
132
- ]
153
+ children: [/* @__PURE__ */ jsx("input", {
154
+ type: "checkbox",
155
+ checked: p.mirrorX,
156
+ onChange: (e) => p.onToggleMirrorX(e.target.checked)
157
+ }), /* @__PURE__ */ jsx("span", { children: "Mirror X=0" })]
133
158
  }),
134
- /* @__PURE__ */ f("div", {
159
+ p.onToggleSnapAxles && /* @__PURE__ */ jsxs("label", {
135
160
  style: {
136
- display: "grid",
137
- gridTemplateColumns: "repeat(4, 1fr)",
138
- gap: 4
161
+ display: "flex",
162
+ alignItems: "center",
163
+ gap: 7,
164
+ cursor: "pointer"
139
165
  },
140
- children: [
141
- ["Kei", 3.4],
142
- ["Coupe", 4.2],
143
- ["Truck", 4.7],
144
- ["Van", 5.2]
145
- ].map(([e, n]) => /* @__PURE__ */ f(t, {
146
- label: `${e} ${n}m`,
147
- active: Math.abs(v.targetMeters - n) < .08,
148
- color: "#38BDF8",
149
- center: !0,
150
- onClick: () => v.onChangeTargetMeters(n)
151
- }, e))
166
+ children: [/* @__PURE__ */ jsx("input", {
167
+ type: "checkbox",
168
+ checked: p.snapAxles ?? true,
169
+ onChange: (e) => p.onToggleSnapAxles(e.target.checked)
170
+ }), /* @__PURE__ */ jsx("span", { children: "Snap Axles" })]
152
171
  }),
153
- /* @__PURE__ */ f(a, {
154
- label: "Length",
155
- value: v.targetMeters,
156
- min: .6,
157
- max: 18,
158
- step: .05,
159
- display: `${v.targetMeters.toFixed(2)}m`,
160
- onChange: v.onChangeTargetMeters
161
- }),
162
- /* @__PURE__ */ f(t, {
163
- label: "Ground Tires to Y = 0",
164
- color: "#10B981",
165
- center: !0,
166
- onClick: v.onSnapYZero
172
+ p.onToggleSealArchLiner && /* @__PURE__ */ jsxs("label", {
173
+ style: {
174
+ display: "flex",
175
+ alignItems: "center",
176
+ gap: 7,
177
+ cursor: "pointer"
178
+ },
179
+ children: [/* @__PURE__ */ jsx("input", {
180
+ type: "checkbox",
181
+ checked: p.sealArchLiner ?? true,
182
+ onChange: (e) => p.onToggleSealArchLiner(e.target.checked)
183
+ }), /* @__PURE__ */ jsx("span", { children: "Seal Arch Liners" })]
167
184
  }),
168
- /* @__PURE__ */ f(t, {
169
- label: "Next: 2 · Segment Shell ->",
170
- active: !0,
171
- color: "#FFB000",
172
- center: !0,
173
- onClick: () => v.onChangeWizardTab("shell")
185
+ p.onApplyWheelCutters && /* @__PURE__ */ jsx(Btn, {
186
+ label: "Core Wheels",
187
+ active: cuttersReady,
188
+ disabled: !cuttersReady || p.busy,
189
+ accent: "#00E5FF",
190
+ onClick: p.onApplyWheelCutters
174
191
  })
175
192
  ]
176
193
  }),
177
- v.wizardTab === "shell" && /* @__PURE__ */ p(d, { children: [
178
- /* @__PURE__ */ p("div", {
179
- style: r,
180
- children: [
181
- !S && /* @__PURE__ */ p("div", {
194
+ /* @__PURE__ */ jsxs("div", {
195
+ style: {
196
+ display: "grid",
197
+ gap: 6,
198
+ paddingTop: 6,
199
+ borderTop: "1px solid rgba(255,255,255,0.08)"
200
+ },
201
+ children: [
202
+ /* @__PURE__ */ jsxs("div", {
203
+ style: {
204
+ display: "grid",
205
+ gridTemplateColumns: "1fr 1fr",
206
+ gap: 5
207
+ },
208
+ children: [/* @__PURE__ */ jsx(Btn, {
209
+ label: "Imported Tires",
210
+ active: p.wheelSource === "imported",
211
+ onClick: () => p.onChangeWheelSource("imported")
212
+ }), /* @__PURE__ */ jsx(Btn, {
213
+ label: "12-Gon Fleet",
214
+ active: p.wheelSource === "fleet12",
215
+ accent: "#10B981",
216
+ onClick: () => p.onChangeWheelSource("fleet12")
217
+ })]
218
+ }),
219
+ /* @__PURE__ */ jsx("div", {
220
+ style: {
221
+ display: "grid",
222
+ gridTemplateColumns: "repeat(3, 1fr)",
223
+ gap: 5
224
+ },
225
+ children: [
226
+ "AWD",
227
+ "RWD",
228
+ "FWD"
229
+ ].map((drv) => /* @__PURE__ */ jsx(Btn, {
230
+ label: drv,
231
+ active: p.driveType === drv,
232
+ accent: "#FFB000",
233
+ onClick: () => p.onChangeDriveType(drv)
234
+ }, drv))
235
+ }),
236
+ /* @__PURE__ */ jsxs("label", {
237
+ style: {
238
+ display: "grid",
239
+ gap: 3,
240
+ fontSize: 11.5,
241
+ color: "#94A3B8"
242
+ },
243
+ children: [/* @__PURE__ */ jsxs("div", {
182
244
  style: {
183
- display: "grid",
184
- gridTemplateColumns: "1fr auto",
185
- gap: 4
245
+ display: "flex",
246
+ justifyContent: "space-between"
186
247
  },
187
- children: [/* @__PURE__ */ f(t, {
188
- label: `Auto-Detect Wheels (${v.wheelCount}W)`,
189
- active: v.wheelCount >= 4,
190
- color: "#10B981",
191
- onClick: v.onAutoPopWheels
192
- }), /* @__PURE__ */ f(t, {
193
- label: v.wheelSource === "imported" ? "Mesh" : "12-Gon",
194
- color: "#00E5FF",
195
- onClick: () => v.onChangeWheelSource(v.wheelSource === "imported" ? "fleet12" : "imported")
248
+ children: [/* @__PURE__ */ jsx("span", { children: "Power" }), /* @__PURE__ */ jsx("span", {
249
+ style: { color: "#E6EDF3" },
250
+ children: `${p.horsepower} hp`
196
251
  })]
197
- }),
198
- /* @__PURE__ */ f("span", {
199
- style: {
200
- fontSize: 10,
201
- color: "#94A3B8"
202
- },
203
- children: "PICK PART TO TAG OR CUT"
204
- }),
205
- /* @__PURE__ */ p("div", {
252
+ }), /* @__PURE__ */ jsx("input", {
253
+ type: "range",
254
+ min: 90,
255
+ max: 720,
256
+ step: 10,
257
+ value: p.horsepower,
258
+ onChange: (e) => p.onChangeHorsepower(Number(e.target.value)),
259
+ style: { accentColor: "#FFB000" }
260
+ })]
261
+ })
262
+ ]
263
+ }),
264
+ /* @__PURE__ */ jsxs("details", {
265
+ style: {
266
+ paddingTop: 6,
267
+ borderTop: "1px solid rgba(255,255,255,0.08)"
268
+ },
269
+ children: [/* @__PURE__ */ jsx("summary", {
270
+ style: {
271
+ cursor: "pointer",
272
+ fontSize: 11.5,
273
+ color: "#94A3B8"
274
+ },
275
+ children: "Panel Cut & Hinges"
276
+ }), /* @__PURE__ */ jsxs("div", {
277
+ style: {
278
+ display: "grid",
279
+ gap: 6,
280
+ marginTop: 8
281
+ },
282
+ children: [
283
+ /* @__PURE__ */ jsx("div", {
206
284
  style: {
207
285
  display: "grid",
208
286
  gridTemplateColumns: "1fr 1fr",
209
287
  gap: 4
210
288
  },
211
- children: [(S ? [
212
- "propeller",
213
- "door",
214
- "glass",
215
- "hood"
216
- ] : h).map((e) => {
217
- let n = l.find((t) => t.role === e), r = C(e);
218
- return /* @__PURE__ */ f(t, {
219
- active: v.activeRole === e,
220
- color: n.color,
221
- label: `${n.label}${r > 0 ? ` (${r})` : ""}`,
222
- onClick: () => v.onSelectRole(e)
223
- }, e);
224
- }), /* @__PURE__ */ f(t, {
225
- label: y ? "Less parts ▴" : "More parts ▾",
226
- onClick: () => b((e) => !e)
227
- })]
289
+ children: CHOP_ROLES.map((item) => /* @__PURE__ */ jsx(Btn, {
290
+ label: item.label,
291
+ active: p.activeRole === item.role,
292
+ accent: item.color,
293
+ onClick: () => p.onSelectRole(item.role)
294
+ }, item.role))
228
295
  }),
229
- y && /* @__PURE__ */ f("div", {
230
- style: {
231
- display: "grid",
232
- gridTemplateColumns: "repeat(3, 1fr)",
233
- gap: 4
234
- },
235
- children: g.map((e) => {
236
- let n = l.find((t) => t.role === e), r = C(e);
237
- return /* @__PURE__ */ f(t, {
238
- active: v.activeRole === e,
239
- color: n.color,
240
- label: `${e}${r > 0 ? ` (${r})` : ""}`,
241
- onClick: () => v.onSelectRole(e)
242
- }, e);
243
- })
244
- })
245
- ]
246
- }),
247
- /* @__PURE__ */ p("div", {
248
- style: r,
249
- children: [
250
- /* @__PURE__ */ f("span", {
251
- style: {
252
- fontSize: 10,
253
- color: "#94A3B8"
254
- },
255
- children: "GRAB TOOL"
256
- }),
257
- /* @__PURE__ */ f("div", {
296
+ /* @__PURE__ */ jsx("div", {
258
297
  style: {
259
298
  display: "grid",
260
299
  gridTemplateColumns: "1fr 1fr",
261
300
  gap: 4
262
301
  },
263
- children: _.map((e) => /* @__PURE__ */ f(t, {
264
- label: e.label,
265
- active: v.surfaceMode === e.mode,
266
- color: "#00E5FF",
267
- onClick: () => v.onChangeSurfaceMode(e.mode)
268
- }, e.mode))
302
+ children: MODES.map((m) => /* @__PURE__ */ jsx(Btn, {
303
+ label: m.label,
304
+ active: p.surfaceMode === m.mode,
305
+ onClick: () => p.onChangeSurfaceMode(m.mode)
306
+ }, m.mode))
269
307
  }),
270
- /* @__PURE__ */ f("div", {
271
- style: {
272
- fontSize: 10,
273
- color: "#94A3B8",
274
- lineHeight: 1.3
275
- },
276
- children: _.find((e) => e.mode === v.surfaceMode)?.hint
308
+ p.surfaceMode === "loop" && /* @__PURE__ */ jsx(Btn, {
309
+ label: `Close Loop (${p.loopDotCount})`,
310
+ disabled: p.loopDotCount < 3,
311
+ onClick: p.onCloseLoop
277
312
  }),
278
- v.surfaceMode === "crease" && /* @__PURE__ */ f(a, {
279
- label: "Shutline",
280
- value: v.creaseDeg,
281
- min: 10,
282
- max: 70,
283
- step: 1,
284
- display: `${v.creaseDeg}°`,
285
- accent: "#FFB000",
286
- onChange: v.onChangeCreaseDeg
313
+ p.surfaceMode !== "island" && /* @__PURE__ */ jsx(Btn, {
314
+ label: `Peel ${p.selectedFaces} Faces`,
315
+ active: p.selectedFaces > 0,
316
+ disabled: p.selectedFaces === 0,
317
+ onClick: p.onPeel
287
318
  }),
288
- /* @__PURE__ */ p("label", {
319
+ (p.undoCount > 0 || totalPicked > 0) && /* @__PURE__ */ jsxs("div", {
289
320
  style: {
290
321
  display: "flex",
291
- alignItems: "center",
292
- gap: 6,
293
- fontSize: 10.5,
294
- cursor: "pointer"
295
- },
296
- children: [/* @__PURE__ */ f("input", {
297
- type: "checkbox",
298
- checked: v.mirrorX,
299
- onChange: (e) => v.onToggleMirrorX(e.target.checked),
300
- style: { accentColor: "#00E5FF" }
301
- }), /* @__PURE__ */ f("span", { children: "Mirror Left ↔ Right automatically" })]
302
- }),
303
- v.surfaceMode === "loop" && /* @__PURE__ */ p("label", {
304
- style: {
305
- display: "flex",
306
- alignItems: "center",
307
- gap: 6,
308
- fontSize: 10.5,
309
- cursor: "pointer"
310
- },
311
- children: [/* @__PURE__ */ f("input", {
312
- type: "checkbox",
313
- checked: v.splitCoarse,
314
- onChange: (e) => v.onToggleSplitCoarse(e.target.checked),
315
- style: { accentColor: "#FFB000" }
316
- }), /* @__PURE__ */ f("span", { children: "Split coarse triangles under cut line" })]
317
- }),
318
- (v.surfaceMode !== "island" || v.selectedFaces > 0) && /* @__PURE__ */ p("div", {
319
- style: {
320
- display: "flex",
321
- flexWrap: "wrap",
322
- gap: 4
323
- },
324
- children: [
325
- v.surfaceMode === "loop" && /* @__PURE__ */ f(t, {
326
- label: `Close Loop (${v.loopDotCount})`,
327
- disabled: v.loopDotCount < 3,
328
- color: "#00E5FF",
329
- onClick: v.onCloseLoop
330
- }),
331
- /* @__PURE__ */ f(t, {
332
- label: `PEEL ${v.selectedFaces}${v.mirroredFaces > 0 ? `+${v.mirroredFaces}` : ""} → ${v.activeRole.toUpperCase()}`,
333
- active: v.selectedFaces > 0,
334
- disabled: v.selectedFaces === 0,
335
- color: x.color,
336
- onClick: v.onPeel
337
- }),
338
- (v.selectedFaces > 0 || v.loopDotCount > 0) && /* @__PURE__ */ f(t, {
339
- label: "Clear",
340
- onClick: v.onClearSelection
341
- })
342
- ]
343
- }),
344
- (v.undoCount > 0 || w > 0 || v.propellerCount > 0) && /* @__PURE__ */ p("div", {
345
- style: {
346
- display: "flex",
347
- gap: 4
348
- },
349
- children: [v.undoCount > 0 && /* @__PURE__ */ f(t, {
350
- label: `Undo Cut (${v.undoCount})`,
351
- color: "#F43F5E",
352
- onClick: v.onUndoCut
353
- }), (w > 0 || v.propellerCount > 0) && /* @__PURE__ */ f(t, {
354
- label: "Reset Tags",
355
- onClick: v.onClearTags
356
- })]
357
- })
358
- ]
359
- }),
360
- /* @__PURE__ */ p("div", {
361
- style: r,
362
- children: [
363
- /* @__PURE__ */ f(a, {
364
- label: "Open Parts",
365
- value: v.hingeScrub,
366
- min: 0,
367
- max: 1,
368
- step: .02,
369
- display: `${Math.round(v.hingeScrub * 100)}%`,
370
- accent: "#10B981",
371
- onChange: v.onChangeHingeScrub
372
- }),
373
- /* @__PURE__ */ f(a, {
374
- label: "Explode",
375
- value: v.explodeAmount,
376
- min: 0,
377
- max: 1.2,
378
- step: .02,
379
- display: `${v.explodeAmount.toFixed(2)}m`,
380
- accent: "#FFB000",
381
- onChange: v.onChangeExplodeAmount
382
- }),
383
- /* @__PURE__ */ f(t, {
384
- label: "Next: 3 · Fit Mixamo Cabin ->",
385
- active: !0,
386
- color: "#00E5FF",
387
- center: !0,
388
- onClick: () => v.onChangeWizardTab("cabin")
389
- })
390
- ]
391
- })
392
- ] }),
393
- v.wizardTab === "cabin" && /* @__PURE__ */ f(e, {
394
- shellViewMode: v.shellViewMode,
395
- onChangeShellViewMode: v.onChangeShellViewMode,
396
- cabin: v.cabin,
397
- cabinFit: v.cabinFit,
398
- carBounds: v.carBounds,
399
- onUpdateCabin: v.onUpdateCabin,
400
- onSetCabinLayout: v.onSetCabinLayout,
401
- onAutoFitCabin: v.onAutoFitCabin,
402
- onNextDrive: () => v.onChangeWizardTab("drive")
403
- }),
404
- v.wizardTab === "drive" && /* @__PURE__ */ p("div", {
405
- style: r,
406
- children: [
407
- /* @__PURE__ */ f("span", {
408
- style: {
409
- fontSize: 10,
410
- color: "#94A3B8"
411
- },
412
- children: "DRIVING TUNE (OPTIONAL)"
413
- }),
414
- /* @__PURE__ */ f(a, {
415
- label: "Mass",
416
- value: v.massKg,
417
- min: 80,
418
- max: 12e3,
419
- step: 20,
420
- display: `${v.massKg}kg`,
421
- accent: "#38BDF8",
422
- onChange: v.onChangeMassKg
423
- }),
424
- /* @__PURE__ */ f(a, {
425
- label: S ? "Thrust" : "Power",
426
- value: v.horsepower,
427
- min: S ? 500 : 40,
428
- max: S ? 25e3 : 1600,
429
- step: S ? 100 : 10,
430
- display: S ? `${v.horsepower}N` : `${v.horsepower}HP`,
431
- accent: "#FFB000",
432
- onChange: v.onChangeHorsepower
433
- }),
434
- !S && /* @__PURE__ */ p(d, { children: [
435
- /* @__PURE__ */ f("div", {
436
- style: {
437
- display: "grid",
438
- gridTemplateColumns: "repeat(3, 1fr)",
439
- gap: 4
322
+ gap: 5
440
323
  },
441
- children: [
442
- "AWD",
443
- "RWD",
444
- "FWD"
445
- ].map((e) => /* @__PURE__ */ f(t, {
446
- label: e,
447
- active: v.driveType === e,
448
- color: "#FFB000",
449
- center: !0,
450
- onClick: () => v.onChangeDriveType(e)
451
- }, e))
452
- }),
453
- /* @__PURE__ */ p("label", {
454
- style: {
455
- display: "grid",
456
- gridTemplateColumns: "56px 1fr",
457
- alignItems: "center",
458
- gap: 5,
459
- fontSize: 10
460
- },
461
- children: [/* @__PURE__ */ f("span", { children: "Tires" }), /* @__PURE__ */ f("select", {
462
- style: i,
463
- value: v.tirePreset,
464
- onChange: (e) => v.onChangeTirePreset(e.target.value),
465
- children: s.map((e) => /* @__PURE__ */ f("option", {
466
- value: e,
467
- children: e
468
- }, e))
324
+ children: [p.undoCount > 0 && /* @__PURE__ */ jsx(Btn, {
325
+ label: `Undo (${p.undoCount})`,
326
+ accent: "#F43F5E",
327
+ onClick: p.onUndoCut
328
+ }), totalPicked > 0 && /* @__PURE__ */ jsx(Btn, {
329
+ label: "Clear Tags",
330
+ onClick: p.onClearTags
469
331
  })]
470
332
  }),
471
- /* @__PURE__ */ p("label", {
333
+ /* @__PURE__ */ jsxs("label", {
472
334
  style: {
473
335
  display: "grid",
474
- gridTemplateColumns: "56px 1fr",
475
- alignItems: "center",
476
- gap: 5,
477
- fontSize: 10
336
+ gap: 2,
337
+ fontSize: 11,
338
+ color: "#94A3B8"
478
339
  },
479
- children: [/* @__PURE__ */ f("span", { children: "Torque" }), /* @__PURE__ */ f("select", {
480
- style: i,
481
- value: v.torqueCurve,
482
- onChange: (e) => v.onChangeTorqueCurve(e.target.value),
483
- children: c.map((e) => /* @__PURE__ */ f("option", {
484
- value: e,
485
- children: e
486
- }, e))
340
+ children: [/* @__PURE__ */ jsx("span", { children: `Hinge Preview ${Math.round(p.hingeScrub * 100)}%` }), /* @__PURE__ */ jsx("input", {
341
+ type: "range",
342
+ min: 0,
343
+ max: 1,
344
+ step: .02,
345
+ value: p.hingeScrub,
346
+ onChange: (e) => p.onChangeHingeScrub(Number(e.target.value))
487
347
  })]
488
348
  }),
489
- /* @__PURE__ */ p("label", {
349
+ /* @__PURE__ */ jsxs("label", {
490
350
  style: {
491
351
  display: "grid",
492
- gridTemplateColumns: "56px 1fr",
493
- alignItems: "center",
494
- gap: 5,
495
- fontSize: 10
352
+ gap: 2,
353
+ fontSize: 11,
354
+ color: "#94A3B8"
496
355
  },
497
- children: [/* @__PURE__ */ f("span", { children: "Steer" }), /* @__PURE__ */ f("select", {
498
- style: i,
499
- value: v.steerCurve,
500
- onChange: (e) => v.onChangeSteerCurve(e.target.value),
501
- children: o.map((e) => /* @__PURE__ */ f("option", {
502
- value: e,
503
- children: e
504
- }, e))
356
+ children: [/* @__PURE__ */ jsx("span", { children: `Explode ${p.explodeAmount.toFixed(2)} m` }), /* @__PURE__ */ jsx("input", {
357
+ type: "range",
358
+ min: 0,
359
+ max: 1.2,
360
+ step: .02,
361
+ value: p.explodeAmount,
362
+ onChange: (e) => p.onChangeExplodeAmount(Number(e.target.value))
505
363
  })]
506
364
  })
507
- ] })
508
- ]
365
+ ]
366
+ })]
509
367
  }),
510
- v.statusNote && /* @__PURE__ */ f("div", {
368
+ p.statusNote && /* @__PURE__ */ jsx("div", {
511
369
  style: {
512
- fontSize: 10,
513
- color: "#34D399",
514
- padding: "4px 6px",
515
- background: "rgba(16,185,129,0.1)",
516
- border: "1px solid rgba(16,185,129,0.35)",
517
- borderRadius: 4
370
+ fontSize: 11,
371
+ color: "#34D399"
518
372
  },
519
- children: v.statusNote
373
+ children: p.statusNote
520
374
  }),
521
- /* @__PURE__ */ p("div", {
375
+ /* @__PURE__ */ jsxs("div", {
522
376
  style: {
523
377
  display: "grid",
524
- gap: 5,
378
+ gap: 6,
525
379
  marginTop: "auto"
526
380
  },
527
- children: [/* @__PURE__ */ f(t, {
528
- label: "[ -> STEP 2: TEST DRIVE (WASD) ]",
529
- active: v.unlocked,
530
- disabled: !v.unlocked || v.busy,
531
- color: "#FFB000",
532
- center: !0,
533
- onClick: v.onGoTestDrive
534
- }), /* @__PURE__ */ p("div", {
535
- style: {
536
- display: "grid",
537
- gridTemplateColumns: v.onSpawnWorld ? "1fr 1fr" : "1fr",
538
- gap: 4
539
- },
540
- children: [/* @__PURE__ */ f(t, {
541
- label: v.busy ? "Exporting…" : "Download .GLB",
542
- disabled: !v.unlocked || v.busy,
543
- color: "#00E5FF",
544
- center: !0,
545
- onClick: v.onDownloadGlb
546
- }), v.onSpawnWorld && /* @__PURE__ */ f(t, {
547
- label: v.busy ? "Sealing…" : "Spawn in World",
548
- active: v.unlocked,
549
- disabled: !v.unlocked || v.busy,
550
- color: "#10B981",
551
- center: !0,
552
- onClick: v.onSpawnWorld
553
- })]
554
- })]
381
+ children: [
382
+ /* @__PURE__ */ jsx(Btn, {
383
+ label: "Test Drive",
384
+ active: p.unlocked,
385
+ disabled: !p.unlocked || p.busy,
386
+ accent: "#FFB000",
387
+ onClick: p.onGoTestDrive
388
+ }),
389
+ p.onExportGlb && /* @__PURE__ */ jsx(Btn, {
390
+ label: "Export GLB",
391
+ disabled: p.busy,
392
+ accent: "#00E5FF",
393
+ onClick: p.onExportGlb
394
+ }),
395
+ p.onSpawnWorld && /* @__PURE__ */ jsx(Btn, {
396
+ label: p.busy ? "Spawning…" : "Drive in World",
397
+ active: p.unlocked,
398
+ disabled: !p.unlocked || p.busy,
399
+ accent: "#10B981",
400
+ onClick: p.onSpawnWorld
401
+ })
402
+ ]
555
403
  })
556
404
  ]
557
405
  });
558
406
  }
559
- export { v as ChopShopPanel };
407
+ export { ChopShopPanel };
408
+
409
+ //# sourceMappingURL=ChopShopPanel.js.map