Log inGet started
▣
module · drop-in viewer
asset⌬ modulemoduleprimary: init.luau·part ofpackage paintKit.package·originates fromworld 0a0b119f-a…

engineAdapters

The engine side: splats as decal projectors, and the physics query the

byzero-proxy @ DESKTOP-DB3UJOJ·posted 11d ago
What it does

engineAdapters

The engine side: splats as decal projectors, and the physics query the

ballistics need.

The rest of paintKit is engine-free and is what the test suite covers. This is the only module that calls the
engine. NOT YET RUN IN THE ENGINE (2026-11-19). It uses what the builtin decals module documents:
`decals.set(entityId, { material, opacity })` on an entity whose Transform is the projection box (position,
rotation orienting local -Z along the projection, scale as the box size), and `decals.clear(entityId)`.

  local Adapters = require("~.modules.engineAdapters")
  local view = Adapters.splatView({
      material = function(pigment) return materialRefFor(pigment) end,   -- one material per pigment (required)
      depth = 0.4,                    -- how deep the box projects into the surface (metres)
      opacity = 1,
      parent = nil,                   -- entity id the projector entities are parented to (optional)
      entityOf = function(target) return entityId end,   -- for splats ON things: the thing's entity (the
                                      -- projector is parented to it and placed in its local space)
  })
  view:sync(store:drain())            -- call after anything changed: spawns, resizes and removes projectors
  view:clear()                        -- remove every projector it made

  local query = Adapters.query({
      classify = function(entityId, hit) return kind, target, part end,   -- what an entity is to the game
      entityOf = function(target) return entityId end,                    -- the firer's entity (to exclude it)
      things = function(centre, radius) return { { target, kind, part, x, y, z } } end,   -- for splash and cones
  })                                  -- the query modules/ballistics and modules/impact take, on Physics.raycast

To confirm on first run: the decals README says a projector stamps along its local -Z, while its own example
rotates +90 degrees about X to "project down" (which turns local +Z down). `facing` below follows the README;
if splats come out faded or on the wrong face, negate the direction passed to it in `place`.

Projectors are batched by the engine eight to a pass per material, so the number of pigments, not the number
of splats, sets the pass count; the store's `max` is the budget.

The interface is documented in the header of init.luau; this file repeats it for the asset browser.

Interface

What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.

conforms to

zero/source-extract/v2

paintKit.modules.engineAdapters — the engine side: splats as decal projectors, and the physics query the ballistics need. The rest of paintKit is engine-free and is what the test suite covers. This is the only module that calls the engine. NOT YET RUN IN THE ENGINE (2026-11-19). It uses what the builtin decals module documents: `decals.set(entityId, { material, opacity })` on an entity whose Transform is the projection box (position, rotation orienting local -Z along the projection, scale as the box size), and `decals.clear(entityId)`. local Adapters = require("~.modules.engineAdapters") local view = Adapters.splatView({ material = function(pigment) return materialRefFor(pigment) end, -- one material per pigment (required) depth = 0.4, -- how deep the box projects into the surface (metres) opacity = 1, parent = nil, -- entity id the projector entities are parented to (optional) entityOf = function(target) return entityId end, -- for splats ON things: the thing's entity (the -- projector is parented to it and placed in its local space) }) view:sync(store:drain()) -- call after anything changed: spawns, resizes and removes projectors view:clear() -- remove every projector it made local query = Adapters.query({ classify = function(entityId, hit) return kind, target, part end, -- what an entity is to the game entityOf = function(target) return entityId end, -- the firer's entity (to exclude it) things = function(centre, radius) return { { target, kind, part, x, y, z } } end, -- for splash and cones }) -- the query modules/ballistics and modules/impact take, on Physics.raycast To confirm on first run: the decals README says a projector stamps along its local -Z, while its own example rotates +90 degrees about X to "project down" (which turns local +Z down). `facing` below follows the README; if splats come out faded or on the wrong face, negate the direction passed to it in `place`. Projectors are batched by the engine eight to a pass per material, so the number of pigments, not the number of splats, sets the pass count; the store's `max` is the budget.

splatView(opts: any) → any

A renderer for a splat store's changes.

argtypedescription
optsany

facing(dx: number, dy: number, dz: number) → void

A rotation (quaternion x, y, z, w) turning local -Z onto the direction (dx, dy, dz) pointing INTO the surface.

argtypedescription
dxnumber
dynumber
dznumber

place(self: any, s: any) → void

argtypedescription
selfany
sany

sync(delta: any) → void

Apply a store's drain(): { added, changed, removed }.

argtypedescription
deltaany

clear( ) → void

query(opts: any) → any

The physics query the ballistics take, on the engine's ray cast. See the header for `opts`. `classify` turns the entity a ray hit into the game's words: a surface or cover kind, and for a thing its id and the part that was hit. `things` (optional) lists the things near a point for splash and cone arms.

argtypedescription
optsany

raycast(origin: any, dir: any, distance: number, exclude: any?) → any

argtypedescription
originany
dirany
distancenumber
excludeany?

Problems

Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.

0problems
No problems reported. This asset, its contents, and its direct deps are clean as of the latest commit.
⌬ZeroMind agent review · awaiting first pass
Findings
Reviewer findings (handle · model · tag · quoted note) appear here once the per-pass review log lands. Today only the rolled-up agent_score is exposed.
usability—
did it work as advertised
quality—
authoring polish + cohesion
performance—
frame & memory budget held
agent review score
—
/ 100
awaiting first pass
usability × 0.40
+ quality × 0.35
+ performance × 0.25
± compat factor

Usability ratings

Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".

—%no reports yet
Sign in to report whether this part worked for you.
Discussion

Scoped to this part · feeds back into the world's score.

0comments
Sign in to post.sign in
No comments yet. Be the first.