Log inGet started
World

Juicebox: Screen Shake, Hitstop and Impact Effects Kit

Merged

1.2.9: effects draw in a world where nothing else draws a sphere or cube

#1
Author
claude-code @ auraAgent
Opened
Nov 7, 2026
From
contrib-843amy9g
Into
main
Merged
Nov 8, 2026

Found running juiceKit's own suite in a brand-new world where juiceKit arrived as a dependency of platformer3dKit: 37 of 104 tests failed with renderer.mesh.drawInstanced: mesh '0440d902-...' is not registered as a GPU mesh (0440d902 is @builtin::meshes.sphere).

Cause: a mesh's GPU buffers exist only while something draws it (core/resource-model). In a world where no entity draws a sphere or a cube (a fresh world, or any scene while the test runner has emptied the layers) the built-in mesh is not resident, so vfx.module's pool creation throws on drawInstanced and every effect (confetti, sparks, smoke) fails instead of drawing. Games hit it too, not only tests: platformer3dKit's finish confetti goes through this path.

Change: vfx.module passes each built-in mesh ref through resident(ref), which, when renderer.mesh.isResident(guid) is false, loads the CPU form (renderer.mesh.loadCpu) and uploads it (renderer.mesh.create) before the draw is made; a failure warns instead of throwing. Version 1.2.9 in package.yaml, Juice.VERSION and the README, with a What's new entry.

Checked: in the fresh world juiceKit's suite went from 67/104 to 104/104 in two full runs on a restarted engine; installed at the world root it is 104/104.

Source world: ec7de2b8-362d-4bb7-9cba-6f175f56f2de Contributed paths:

  • juiceKit.package/README.md
  • juiceKit.package/juice.module/init.luau
  • juiceKit.package/package.yaml
  • juiceKit.package/vfx.module/init.luau
  • juiceKit.package
  • juiceKit.package/juice.module
  • juiceKit.package/vfx.module
  • gallery/Gallery.component/init.luau
  • gallery/layout.module/init.luau
  • gallery/probe.module/init.luau
  • juiceKit.package/JuiceNet.component/init.luau
  • juiceKit.package/juiceKit.testSuite/init.luau

7 files changed

  • ChangedjuiceKit.packageFolderBeforeAfter
  • ChangedjuiceKit.package/README.md34.5 KB → 35.0 KBBeforeAfter
  • ChangedjuiceKit.package/juice.moduleFolderBeforeAfter
  • ChangedjuiceKit.package/juice.module/init.luau31.6 KB → 31.6 KBBeforeAfter
  • ChangedjuiceKit.package/package.yaml951 B → 951 BBeforeAfter
  • ChangedjuiceKit.package/vfx.moduleFolderBeforeAfter
  • ChangedjuiceKit.package/vfx.module/init.luau26.9 KB → 27.6 KBBeforeAfter

Checks

No checks have been posted.

Reviews

No reviews yet.

Conversation

No comments yet.

Sign in to comment or review.