spoint 0.1.627 → 0.1.629

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.
package/client/app.js CHANGED
@@ -423,7 +423,7 @@ async function _finishLoading() {
423
423
  // real headroom for a cold GPU/shader-compile stall.
424
424
  const SCENERY_BUILD_TIMEOUT_MS = 30000
425
425
  if (_terrainCfg && !terrainBackdrop) {
426
- loadingMgr.setLabel('Building world...')
426
+ loadingMgr.setLabel('Building world (first load can take up to 30s)...')
427
427
  let _sceneryTimedOut = false
428
428
  try { await Promise.race([_buildWorldScenery(), new Promise(r => setTimeout(() => { _sceneryTimedOut = true; r() }, SCENERY_BUILD_TIMEOUT_MS))]) }
429
429
  catch (e) { console.error('[terrain] scenery build failed:', e?.message || e) }
@@ -429,12 +429,14 @@ export async function warmupShaders(renderer, scene, camera, entityMeshes, playe
429
429
  // try/finally guarantees the restore runs on every exit path -- return, throw, or abort.
430
430
  try {
431
431
  // must compile ONLY entity+player meshes, not the whole scene -- InstancedMesh2 veg/rocks reference instanceIndex outside per-object setup and raise a VALIDATE_STATUS error; they warm via their own render() pass
432
+ let compiledCount = 0
432
433
  for (const m of allMeshes) {
433
434
  if (abortSignal?.aborted) { _record({ aborted: true, total, manifestedCount: manifestedMeshes.length }); return }
434
435
  try { await renderer.compileAsync(m, camera, scene) } catch (_) { try { renderer.compile(m, camera, scene) } catch (_2) {} }
436
+ compiledCount++
437
+ loadingMgr.reportProcessing(compiledCount, total)
435
438
  }
436
439
  if (abortSignal?.aborted) { _record({ aborted: true, total, manifestedCount: manifestedMeshes.length }); return }
437
- loadingMgr.reportProcessing(Math.floor(total / 2), total)
438
440
  renderer.shadowMap.needsUpdate = true
439
441
  renderer.render(scene, camera)
440
442
  await new Promise(r => requestAnimationFrame(r))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spoint",
3
- "version": "0.1.627",
3
+ "version": "0.1.629",
4
4
  "description": "Physics and netcode SDK for multiplayer game servers",
5
5
  "type": "module",
6
6
  "workspaces": [