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

impact

What a hit does: one place where cover, marks, surface rules and pigment properties meet.

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

impact

What a hit does: one place where cover, marks, surface rules and pigment properties meet.

Given a projectile that ended on something (modules/ballistics) or a cone pulse (modules/arms), it adds cover
to the thing or leaves a mark on the surface, starts the timed effects the surface rule and the pigment ask
for, bursts a splash over what stands near, and reports everything it did, including the offences the config
attaches to those moments, so the game can tell whoever tracks crimes. It owns no state of its own: it writes
to the stores it is given.

  local Impact = require("~.modules.impact")
  local impact = Impact.new(cfg, { cover = cover, splats = splats, field = field, query = query })
  -- cover: modules/cover; splats: modules/splats; field: Surfaces.field(); query: as modules/ballistics
  --   (query is only needed for splash)
  local report = impact:land(event.shot, event.hit)        -- after Ballistics:step returned an "impact"
  local reports = impact:pulse(cone)                        -- a cone arm's pulse (needs query.overlap)
  -- report = {
  --   target, kind, part,                 what was hit (target nil for the static world)
  --   pigment, arm, owner,
  --   splat = id | nil,                   the mark it left
  --   cover = { event, ... },             modules/cover's events for this hit (cover, effect, out)
  --   effects = { { effect, id, seconds, radius, factor, x, z } },   timed effects started on the field
  --   offences = { name, ... },           offences the config names for what happened, in order, no repeats
  --   splashed = { report, ... } }        the same for each thing the splash reached

Rules, all data: a hit on a thing whose `kind` is a cover kind adds `shot.cover` x the pigment's cover factor
(x the splash share); a "blind" effect lasts its seconds x the pigment's blind factor; a hit on anything else is
looked up in cfg.surfaces[kind] by the arm's name ("mark" leaves a splat, anything else starts an area effect
of rule.radius round the point and still leaves the mark); a pigment's own effects for that kind are added.

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.impact — what a hit does: one place where cover, marks, surface rules and pigment properties meet. Given a projectile that ended on something (modules/ballistics) or a cone pulse (modules/arms), it adds cover to the thing or leaves a mark on the surface, starts the timed effects the surface rule and the pigment ask for, bursts a splash over what stands near, and reports everything it did, including the offences the config attaches to those moments, so the game can tell whoever tracks crimes. It owns no state of its own: it writes to the stores it is given. local Impact = require("~.modules.impact") local impact = Impact.new(cfg, { cover = cover, splats = splats, field = field, query = query }) -- cover: modules/cover; splats: modules/splats; field: Surfaces.field(); query: as modules/ballistics -- (query is only needed for splash) local report = impact:land(event.shot, event.hit) -- after Ballistics:step returned an "impact" local reports = impact:pulse(cone) -- a cone arm's pulse (needs query.overlap) -- report = { -- target, kind, part, what was hit (target nil for the static world) -- pigment, arm, owner, -- splat = id | nil, the mark it left -- cover = { event, ... }, modules/cover's events for this hit (cover, effect, out) -- effects = { { effect, id, seconds, radius, factor, x, z } }, timed effects started on the field -- offences = { name, ... }, offences the config names for what happened, in order, no repeats -- splashed = { report, ... } } the same for each thing the splash reached Rules, all data: a hit on a thing whose `kind` is a cover kind adds `shot.cover` x the pigment's cover factor (x the splash share); a "blind" effect lasts its seconds x the pigment's blind factor; a hit on anything else is looked up in cfg.surfaces[kind] by the arm's name ("mark" leaves a splat, anything else starts an area effect of rule.radius round the point and still leaves the mark); a pigment's own effects for that kind are added.

new(cfg: any, stores: any) → any

argtypedescription
cfgany
storesany

note(list: { string }, offence: string?) → void

argtypedescription
list{ string }
offencestring?

start(self: any, report: any, e: any, id: string?, x: number, z: number) → void

argtypedescription
selfany
reportany
eany
idstring?
xnumber
znumber

land(self: any, shot: any, hit: any, share: number, splash: boolean) → any

argtypedescription
selfany
shotany
hitany
sharenumber
splashboolean

land(shot: any, hit: any) → any

A projectile ended on something. See the header for the report.

argtypedescription
shotany
hitany

pulse(cone: any) → void

A cone arm's pulse: everything it reaches takes the pulse's cover. Returns one report per thing, nearest first.

argtypedescription
coneany

Problems

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

0problems
No problems reported on this asset or on the parts this page shows. Parts it leaves out are not counted here.
⌬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.