Log inGet started
Package

assassinationKit.package

This package holds more than this page lists. See all of its files in its world.

README.md

assassinationKit.moment: the kill moment, the accident visuals and the kit's sound. Called by the HUD (accident fx events, mission events), by the client (direct kills), by the screens (button sounds) and by a scene's entrypoint (ambience and music beds). Everything runs on the peer that calls it; the mission's events already reach every peer, so nothing is sent.

The kill moment

Moment.kill({ entity = body, text = "The net gives way...", mine = true })

  • The killer's screen: a 0.7 s time slow (engine.holdTimeScale(0.3), released on the wall clock), a camera push (field of view in by 7 degrees and back over 1.6 s), a heavy shake at low intensity, impactFrames' inkSplash in sepia ink on parchment (Moment.INK, Moment.PAPER, Moment.ACCENT; never red, never black), sepia ink droplets, wash and paper flecks at the body (juiceKit vfx, look soInk), the ink sting, and a title card with the accident's text.
  • Players within 40 m: a lighter stroke, the ink at the body, a light shake, the sting quieter. No time slow, so nobody else's simulation is touched.
  • Everyone else: the title card only.

A staged kill's moment waits for its accident to land (the load hitting the pier, the glass breaking, the railing going): mission.stagedKill broadcasts an fx event of kind kill with the text, and the HUD hands it here.

Accident visuals (Moment.accident(ev))

kindwhat is seen and heard
heavyDropa cargo net of crates (concealKit's crates under a rope net with slings, a hook and the snapped line) falls from crane height, lands in dust with a rumble; cargo crash sound
poisonthe glass slips, tumbles and breaks with a glint; glass shatter and the body slumping
sabotagea railing section tips over and drops into the water with a splash; wood crack and splash
riggedSwapa snap and a small ink burst; spring snap
impersonate, lure, guardAway, doorOpena quiet cue: a faint ink puff and the opening motif

Sound

  • Moment.sound(name, { volume?, pitch?, at? }): one of Moment.SOUNDS (inkSting, cargoCrash, glassSlump, railSplash, riggedSnap, openingCue, intelChime, stepDone, oppReveal, exitWhoosh, gradeStamp, uiClick, uiHover, paperRustle). at makes it spatial. Each sound has a short gap so a burst of events never stacks it.
  • Moment.uiSound(name): screen buttons: click, hover, open / select (paper rustle), stamp (debrief grade), leave (exit whoosh).
  • Moment.hudEvent(name, ev, c, pub): intel chime, step tick, opportunity reveal, done tick, and a lighter moment for another player's direct kill nearby.
  • Phase cues: the contract ambience loops on the select and briefing screens (ducking the harbour beds), a paper rustle as they open, the grade stamp on the debrief.
  • Moment.beds({ ambience = clip, calm = clip, tense = clip, ambienceVolume?, musicVolume? }): looping beds; the music cross-fades calm to tense while stealthKit's alert is raised and for 14 s after a kill. Moment.stopBeds(), Moment.bedState().

Channels: sfx, ui, music, ambience, so audio.setChannelVolume, audio.setMasterVolume and audio.setMuted (a settings screen) reach every sound here.