Log inGet started
World

Open Sesame: Doors, Switches, Locks and Chests Kit

README.md

interactKit

Version 1.6.7. Everything a player can walk up to and use, for any Zero game: seven doors, seven switches and levers, key, coloured keycard and combination locks, chests and other containers that hand out loot, a barricade and invisible trigger zones, with "Press E to open" and hold-to-use prompts on keyboard, gamepad and a phone's touch screen. Five prompt styles and six looks (old wood, sci-fi, cartoon, dungeon, neon, royal palace), each picked with one field, sounds for every door, switch, chest and lock, and multiplayer from the ground up: every player sees the same door, lever and chest. Ships with two guides, a how-to and a worked escape room example. To install, search ZeroMind for interactKit, or run zero zeromind installAsset f7af5474-4cb3-48d3-96e6-15f897ccce4f in the engine shell, then local Interact = require("~interactKit.api").

  • Interactable: put it on anything. A prompt appears when the player is close enough (trigger = "proximity") or looking at it (trigger = "look") within range. holdTime = 0 is a quick press; above 0 the player holds while a fill-up runs. One interact button everywhere: E, the gamepad's west face button (X on Xbox, square on PlayStation, Y on Switch), or the on-screen Interact button on a phone.
  • TriggerVolume: an invisible box or sphere that reports enter, exit and stay for every player, and can open, close or toggle what it is wired to.
  • 7 doors, 7 switches, 3 locks, 4 containers, a barricade, 5 prompt styles, 6 looks, listed below.

Everything works the same way: a kind field picks the variant, a look field picks the style, targets wires it to other things by name, and one field picks the prompt style. Swapping a sliding door for a portcullis is changing kind = "sliding" to kind = "portcullis".

Install

Search ZeroMind for interactKit and install interactKit.package, or in the engine shell:

zero zeromind installAsset f7af5474-4cb3-48d3-96e6-15f897ccce4f

It lands at /source/interactKit.package and brings its two dependencies with it, controlsKit and juiceKit (under /source/deps/). Keys, keycards, coins and gems are interactKit's own, so nothing else is needed.

Reach interactKit by its package name, require("~interactKit.api"), and its components with Interact.component("Door"): both work wherever the package is installed, at the top of /source or under deps/ when another kit depends on it.

Quick start

A new world's scenes/main.scene/build.luau already has a ground and a player. Add these lines at the end of its content() function:

    -- ── interactKit quick start ─────────────────────────────────────────
    local Interact = require("~interactKit.api")

    -- a door in a short wall, and a lever beside it that opens it
    Interact.spawn("door.hinged", { 0, 0, 6 }, { name = "FrontDoor", synced = true, yaw = 180,
        look = "wood", fields = { wall = 1.5 } })
    Interact.spawn("switch.lever", { 2.6, 0, 5 }, { synced = true, yaw = 180, look = "wood",
        fields = { targets = { "FrontDoor" } } })

    -- a locked chest, and the key that opens it (each player picks up their own)
    Interact.spawn("container.chest", { -3, 0, 6 }, { synced = true, yaw = 180, look = "cartoon",
        fields = { loot = "coin", lootCount = 8 }, lock = { kind = "key" } })
    Interact.spawnKey({ -3, 0, 3.5 })

Press Play. Walk to the lever on your left and press E: the door swings open and you can walk through. The chest on your right says Locked: Needs a key; walk over the key, come back, and it says Unlock. Press E and coins spill out.

synced = true makes each thing one shared object, so every player sees the same door. Without it every player gets their own copy.

Doors in your own walls. Build your wall with a gap and put the door in it with a little wall of its own (wall = 0.8 for a 1.4 m door in a 2.8 m gap). The door's wall pieces tuck into your wall and take your wall's material and colour by themselves, as do a portcullis's stone jambs and gatehouse: the door looks just beside its frame for the wall it sits in. Or leave wall at 0 and cut the gap to the frame. wallMaterial picks the stonework yourself; matchWalls = false keeps the look's own stone. More under Doors below.

No code at all: add interactKit.Door (or Switch, Container, Barricade, TriggerVolume, Interactable, Lock) to an entity in the editor and set kind, look and targets in the inspector. A device works on its own; add an Interactable beside it only to change its prompt (range, look-at, hold time, style).

The gallery scene (interactKit.gallery) has every kind, look and prompt style laid out, labelled and usable.

Guides

Two guides ship in the package, in interactKit.package/guides/, and come with every install:

  • how-to-make-doors-switches-locks-and-chests: every part of the kit, from a "Press E" prompt to keys in another inventory.
  • example-escape-room-puzzle-with-switches-and-locked-doors: an empty world to a treasure vault puzzle with inventoryKit and dialogueKit.

Open one in the editor's Docs panel (search its name, or what you want to do, such as "lever opens door"), or in the engine shell with zero guides read <name> or man <name>. To read one before installing: zm show @f7af5474-4cb3-48d3-96e6-15f897ccce4f:interactKit.package/guides/<name>.guide/guide.md.

The family

interactKit is the first kit of a family made to work together: interactKit, inventoryKit (the bag, items and loot, package e5580df4-1900-4b90-a890-3f5a30501f2a), craftingKit (stations, recipes and gathering on inventoryKit's items, package db435e42-06aa-407e-8537-106d444d0a5c) and dialogueKit (characters who talk, package c4f39ad3-2a14-4f7d-b409-aed7fdbe8e77), with questKit beside them (quests on all four, package 207320c0-8bf2-4175-ba37-fdcf2c915679). questKit's guides: How to add quests to my game (zm show @915ee882-7aef-4388-803f-cb96a4160fbe:guide.md) and Example: a quest chain from an empty world (the mushroom quest chain, zm show @f06a2f9d-29a2-41e5-b242-9e21043e5db1:guide.md). inventoryKit, craftingKit and dialogueKit have no guides yet; their READMEs are the reference.

dialogueKit 1.0.2, craftingKit and questKit install interactKit themselves. dialogueKit 1.0.2 brings its own copy of interactKit 1.3.1 for its Talker's prompt; next to a newer interactKit at the top of a world that copy's prompts do not show, so start conversations from an interactKit Interactable instead, as the escape room example does.

Styles

Doors: interactKit.Door, kind =

KindWhat it is
hingedA single door swinging on side hinges.
doubleTwo leaves swinging apart from the middle.
slidingA barn or shop door rolling sideways on a rail.
garageSlats rolling up into a drum over a wide opening.
portcullisAn iron grid rising into a stone gatehouse.
bookcaseA full bookcase that swings away to reveal a passage.
airlockSplit halves sliding into the walls, with a red / green status light.

Moving parts carry their colliders: an open door is a doorway you walk through, a closed one is a wall.

Setting a door into your own walls. Leave wall at 0 (the default) and the door brings only its frame: cut your doorway to the frame (the opening plus about 0.14 m a side for most kinds, 0.5 m a side for the portcullis). Give it wall metres to have it fill a wider gap with wall pieces of its own. Either way the door's stonework (its wall pieces, and a portcullis's stone jambs and gatehouse) takes the material and colour of the wall it sits in, found by looking just beside the frame through the wall's collider (matchWalls, on by default; it looks a few times while the level loads, and again whenever a wall moves in the editor). wallMaterial sets the stonework yourself and wins over the match: Interact.spawn("door.portcullis", pos, { fields = { wall = 0.8, wallMaterial = myStone } }). matchWalls = false keeps the look's plain stone colour. Things other interactKit objects build are never matched, so doors side by side do not copy each other.

Switches: interactKit.Switch, kind =

KindHow it worksTells its targets
leverPress to throw on / off.follow (open while on)
buttonPress; it pops back up.toggle on every press
plateOn while any player stands on it. No button.follow
keypadPress, type code on the pad.follow
valveHold to spin the wheel a full turn; hold again to close.follow
crankHold to wind; let go early and it unwinds.follow
chainPress to pull.toggle on every pull

Locks: interactKit.Lock, kind =

KindOpens for
keyThe player holding a key (Interact.spawnKey(pos)). Drawn as a padlock.
keycardThe player holding a keycard of the lock's color: red, blue, green, yellow, purple or white (Interact.spawnKey(pos, { kind = "keycard", color = "red" })). A red card opens red locks and not blue ones. Drawn as a card reader in that colour.
combinationWhoever dials code (digits). Drawn as a dial.

A Lock sits beside any Door, Container or Switch on the same entity.

Containers: interactKit.Container, kind =

chest (lid swings up), crate (lid pops off), locker (door swings open), barrel (lid flips). The first open spills lootCount items of loot on the ground in front: coin, gem, key or keycard, with a colour as gem:red or keycard:blue (older pickupsKit look names such as fantasy_ruby are read as the nearest kind). Each piece goes to the first player to walk over it.

Items: interactKit.Item, kind =

KindGives
keykeysOpens key locks for the player holding it.
keycardkeycard_<color>Red, blue, green, yellow, purple or white; opens keycard locks of that colour.
coincoinsWhat containers spill by default.
gemgemsA cut gem in any key colour.

Walk over one to pick it up. perPlayer (the default for keys) means every player takes their own copy, and each sees only their own disappear; shared items go to whoever is first. item gives a different item name, amount more than one, respawn brings it back. Every player's counts are kept in interactKit's own inventory, shared by the host, and shown in a small strip in the top-left corner of each player's screen once they carry something.

Barricade: interactKit.Barricade

Hold to nail boards across an opening one at a time; once full, hold to tear them down. It blocks the way while any board is up.

Prompt styles: promptStyle =

StyleWhat it looks like
glyph (default)The interact button as it looks on the device in hand (E keycap, Xbox X, PlayStation square, Switch Y, generic pad, or a TAP / HOLD badge on a phone) with the action beside it.
ringA radial ring around the button that fills while holding.
tooltipA small card floating over the object: its name, the button and the action.
dotA small dot on every usable thing nearby that grows into the button when focused.
pixelA chunky pixel-art box with a pixel glyph and a segmented hold bar.

The whole world, one field: put interactKit.InteractSettings on any one entity and set its promptStyle (from code: Interact.setPromptStyle("ring")). One object, one field: promptStyle on its Interactable; default follows the world setting. Both apply at once, also while playing.

Looks: look =

LookWhat it looks like
woodOld wood and iron: dark planks, black straps, brass fittings.
scifiSci-fi metal: brushed steel panels with glowing cyan trim.
cartoonChunky bright plastic in candy colours.
dungeonDungeon stone and rust: weathered grey oak, rough stone frames, rusted iron, torch-orange lights.
neonNeon: gloss black panels edged with hot magenta and cyan light.
royalRoyal palace: ivory panels, white marble and polished gold.

Every door, switch, lock badge, container, item and the barricade comes in all six. A look belongs to each object; changing it rebuilds that object in place, also while playing.

Wiring without code

Every Switch, Door, Container, Barricade, TriggerVolume and plain Interactable has targets: a list of entity names (or ids). What they are told:

SourceSends
Lever, plate, keypad, valve, crankfollow (open while on, close while off). Set action to invert, toggle, open, close, unlock or lock to change it.
Button, chaintoggle on every press / pull
TriggerVolumeenterAction when the first player enters, exitAction when the last leaves (once = only the first time)
Door, Containerfollow: opens its targets with it
Barricadeclose when the first board goes up, open when the last comes down
Interactableits action when used

Doors and containers take open, close, toggle; switches take on / open, off / close, toggle; anything with a Lock takes unlock and lock. playerOperable = false on a door means only wiring moves it (a portcullis behind a crank).

API

local Interact = require("~interactKit.api") is the stable public surface, together with the components below. The other modules in the package are internal.

Constants

NameValue
Interact.VERSION"1.6.7" (matches package.yaml and this README)
Interact.PROMPT_STYLES{ "glyph", "ring", "tooltip", "dot", "pixel" }
Interact.LOOKS{ "wood", "scifi", "cartoon", "dungeon", "neon", "royal" }
Interact.SOUNDS{ "doorWood", "doorHeavy", "doorSlide", "lever", "button", "chest", "unlock", "locked", "collect", "hammer" }
Interact.ACTIONS{ "toggle", "open", "close", "follow", "invert", "unlock", "lock" }

Building

CallDoes
spawn(id, pos, opts?) -> entitySpawns any catalog kind ("door.airlock", "switch.valve", "container.chest", "barricade.boards", "core.trigger"...). opts: name, synced (true for shared state), yaw (degrees), look, fields (the component's fields), lock (Lock fields, adds a Lock), interact (Interactable fields, or false for none). Errors on an unknown id.
spawnKey(pos, opts?) -> entityA key or keycard players pick up by walking over it (an interactKit.Item), counted per player. opts: kind ("key" / "keycard"), color (keycards), look (wood, scifi, cartoon), perPlayer (default true: every player picks up their own), respawn, respawnTime, name, synced (default true). Same as spawn("item.key", pos, ...).
catalog(filter?) -> { entry }Every kind: { id, family, kind, name, component, description, tags, looks, hold, wireable }. Filters combine: { family = "door", tag = "scifi", look = "cartoon", hold = true, component = "Switch" }. Copies.
kinds(family) -> { string }The kinds of "door", "switch", "lock", "container", "barricade", "prompt" or "core".
tags() -> { string }Every tag in use, sorted.

Using and wiring

CallDoes
use(target, args?, cb?)Uses target (entity, id or name) as the local player would. args: code (keypads, combinations), expect (the state you saw), scripted = true (skip the reach check, for cutscenes and scripts). cb(ok, reason) gets the owner's answer. Errors on an unknown target.
signal(target, action, cb?)Sends a wiring action (open, close, toggle, on, off, unlock, lock) as a switch would.
fire(sourceId, targets, action, on, peer?)Sends action to every target in the list; follow / invert become open or close from on. Never sends to sourceId itself.
idOf(target) -> id? / resolve(target) -> id?An entity, id or name to an entity id, or nil.
component(name) -> typeinteractKit's component type by short name (Interactable, TriggerVolume, Door, Switch, Lock, Container, Barricade, Item, InteractSettings, InteractHUD) for e.component.add(Interact.component("Door"), { kind = "airlock" }), get and has. Errors on an unknown name.

Events

CallDoes
on(target, name, fn) -> unsubscribefn(ev, entityId) on every peer. target is an entity, id, name, or "*" for all. Events: use, open, close, on, off, unlock, lock, denied (ev.reason), loot, board, unboard, press, pull, enter, exit, stay (ev.dt), holder, collect. ev.peer is the player's peer id where there is one. Call the returned function to stop listening (in a scene entrypoint, from onUnload).
emit(entityId, name, data?)Fires an event on this peer only (for your own devices).

Reading state

CallDoes
statusOf(id, peer) -> tableWhat the prompt says for that player: label, hint, available, state, locked, busy, needsCode, codeLength, progress.
settingsOf(id) -> table?The merged prompt settings: label, trigger, range, holdTime, promptStyle, promptOffset, active, exclusive.
usable() -> { id }Every usable thing this peer knows.
device(target) -> record? / lock(target) -> record?The registered device or lock behind an entity.

Settings

CallDoes
setPromptStyle(style) / promptStyle()The world's prompt style (what InteractSettings.promptStyle sets). Errors on an unknown style.
setShowLabels(on) / showLabels()Action text beside the button.
setEffects(on)juiceKit feedback on open / close.
setSoundVolume(v), getSoundVolume()Volume of interactKit's own sounds on this peer, 0 to 1 (default 0.8; 0 is silent).

Keys, keycards and effects

CallDoes
count(peer, item) -> number / give(peer, item, n) -> booleanA player's items: keys, keycard_red, coins, ... in interactKit's inventory (n may be negative; never below 0). A give on a peer that does not own the inventory is sent to its owner.
items(peer) -> tableEverything that player carries: { keys = 1, coins = 8 } (a copy).
keyOf(peer) -> stringThe key a player's counts are kept under ("p<peer>").
setInventory({ count = fn(peer, item), give = fn(peer, item, n), counts = fn(peer)?, onPlayer = bool? } or nil)Use your own inventory for locks, items and loot instead of interactKit's; nil goes back. interactKit calls these on the owner of the lock or item, with the player's peer id. With onPlayer = true, give runs instead on the engine of the player who gets the item, exactly once.
juice()juiceKit's Juice module, or nil and why not.
fx(preset, at, opts?)Plays a juiceKit preset on this peer only.
sound(name, at, opts?) -> id?Plays one of Interact.SOUNDS at a world point on this peer only (opts.volume); the emitter removes itself. Doors, switches, chests, locks, items and the barricade already play theirs.

Keys in inventoryKit's bag: inventoryKit lets every engine read every bag but only a player's own engine change it, so count reads Inventory.count(item, peer), and onPlayer = true makes interactKit run give (Inventory.give(item, n)) on that player's own engine, once per item. The how-to guide (Keys in a different inventory) has the lines, and the escape room example uses them. With pickupsKit installed at the top of your world:

local Pickups = require("~pickupsKit.api")      -- your world's own copy
Interact.setInventory({
	count = function(peer, item) return Pickups.get("p" .. peer, item) end,
	give = function(peer, item, n) Pickups.add("p" .. peer, item, n) end,
})

Your own devices

Make anything a usable device with the same prompts, networking and locks:

Interact.registerDevice(entity.id, {
	family = "custom", kind = "bell", comp = myComponentPublic,
	defaults = { label = "Ring", range = 3 },
	status = function(peer) return { label = "Ring the bell" } end,
	handle = function(peer, verb, args)        -- runs on the owner
		if verb == "use" then myComponentPublic.rung += 1; return true end
		return false, "unknown verb"
	end,
	signal = function(action, args) return true end,   -- optional: wiring
})

unregisterDevice(id, record), registerInteractable(id, comp) / unregisterInteractable(id, comp), registerLock(id, { isLocked, setLocked, describe(peer), tryUnlock(peer, args) }) / unregisterLock(id, record). ensureHud() makes sure this peer's prompt HUD exists in play (devices call it for you).

Components

ComponentFields (state fields are written by the owner)
Interactablelabel, title, trigger (proximity / look), range, holdTime, promptStyle, promptOffset, active, exclusive, targets, action; event used
TriggerVolumesize, shape (box / sphere), targets, enterAction, exitAction, once, showInEditor; state count, fired; events entered, exited
Doorkind, look, width, height, wall, wallMaterial, matchWalls, speed, autoClose, playerOperable, active, targets; state open
Switchkind, look, targets, action, code, once, holdTime, active; state on, progress
Lockkind, color, item, code, consume, relock, openOnUnlock, badge; state locked
Containerkind, look, loot, lootCount, lootItem, refill, autoClose, active, targets; state open, looted
Barricadelook, width, height, wall, maxBoards, secondsPerBoard, active, targets; state boards, tearing, work
Itemkind (key / keycard / coin / gem), color, look, item, amount, perPlayer, respawn, respawnTime, radius, removeWhenTaken, active; state available, taken; event collect (ev.peer, ev.item, ev.amount)
InteractSettingspromptStyle (the whole world's), showLabels, effects, soundVolume
InteractInventorySpawned for you in play by the host: every player's counts (counts), written by its owner.
InteractHUDSpawned for you on each player's machine: prompts, hold fill-ups, messages, code pad.

Set a state field in the editor for the starting state (a door that starts open, a barricade that starts boarded).

Multiplayer

  • The owner decides. Any player may ask; the peer that owns the entity (the host, for scene objects) checks reach, the lock, and that the thing is still in the state the player saw, then writes the shared state. Every player animates from it, so all see the same door, lever, chest or barricade, late joiners included.
  • Two players, one handle. Requests carry the state the player saw, so two players pulling the same lever at once flip it once. Holds (valve, crank, barricade, exclusive hold-to-use) are claimed by one player at a time; the other sees "In use by another player", and a claim lapses when its player goes quiet.
  • Keys belong to the player who picked them up. The owner checks the count of the player who asked, so a locked door opens for the player holding the key and refuses the one who isn't.
  • Effects play on every machine from the shared state change; nothing extra is sent. Channels: ik:req, ik:res, ik:evt.

Tests

tools.use("tests", "run", "interactKitTests") in edit mode (shell: zero tests run interactKitTests) runs 97 tests. They cover every public call of interactKit.api (one test fails if a public call is added without a test), every kind in every look, kind swaps, wiring and every switch, per-player keys and keycards, items (per player, shared, out of reach, respawning) and the shared inventory, combination locks, loot, the barricade, trigger volumes, hold claims, simultaneous requests and remote players (stand-in bodies whose requests go through the real network handler), prompt styles and the code pad, a label set on a device's prompt and the Hold to use hint, gives carried once to the receiving player's engine, a door's stonework wearing the wallMaterial it is given or matching the wall it stands in, every look's palette and style, every sound playing once and cleaning up, the gallery's signs showing this version, and that both guides ship, link each other and are named here. Guard tests fail if any code reaches a dependency by folder path, adds a pickupsKit component, or times anything with CPU time, and if a taken item rebuilds or respawns its parts, reappears for the player who took it, or shows again after that player's own repeated grab.

For 1.4.0 the suite was run twice in a row with 86 of 86 passing both times, in this world and in a new world holding only interactKit installed from ZeroMind. In that new world the quick start above was played as written: the lever opens the door, walking over the key counts it, the chest says Locked, then Unlock, and opens, and the spilled coins are collected. The escape room example guide was followed word for word in another new world, alone and with two players. 1.4.1 changes only text; its suite passed 86 of 86 twice in a row here and in a new world with only 1.4.1 installed, where the quick start was played again.

Known limits

Each limit here is an open public issue you can look up.

  • #14448: two copies of the engine signed in to the same account collide as one player. Test two players with two accounts.
  • #21420: an install with several dependencies is slow. interactKit brings two; a game installing interactKit, inventoryKit and dialogueKit waits about a minute.
  • #20750: the frame rate of the web build is low on multiplayer worlds, the gallery included.
  • #20946: the web build of each release is checked by the world's owner; this release was verified in the desktop engine.
  • #19258: the description ZeroMind shows for the package can lag behind a new release for a while.

How it behaves

Design choices rather than limits:

  • The prompt focuses one thing at a time: looking at something in range beats being nearest to something else.
  • Codes are digits only, up to 8.
  • Doors swing one way, away from the side they face, and do not push players aside while closing.
  • Doors, switches and the rest are built from primitive shapes. Their parts are rebuilt on every machine from kind and look and never saved into a scene.
  • In edit mode things snap to their state; they animate in play.

Changes

  • 1.6.7: the gallery's two saved version signs say this version again (they had stayed at 1.6.4; the gallery rewrites them from Interact.VERSION whenever it loads), so the test that checks them passes. Nothing else changes.
  • 1.6.6: The HUD's lastFrame() report also carries rects: every top-level panel it placed at a fixed position this frame (the prompts, the message line) as { id, x, y, w, h } in screen points, so a screen that draws later in the same frame can keep clear of a prompt the moment it appears. Nothing else changes.
  • 1.6.5: Prompts read on any background and on a phone. In the glyph style the hold bar and the Hold to use line now sit on a dark chip of their own under the pill, with a text shadow, instead of bare light text that washed out over bright sand, snow or whatever stood behind the prompt. On a touch screen the focused prompt slides sideways until it clears every on-screen control the engine or the world states (ui.safeArea().controls, which a world adds to with ui.setControlRegions), so a button column no longer covers its label. Nothing changes on a desktop screen with no controls stated.
  • 1.6.4: Built against controlsKit 1.3.2, the release menusKit 1.3.19, saveKit 1.3.13, inventoryKit 1.0.27 and navUiKit 1.3.9 ship with, so a world that installs interactKit beside questKit, economyKit or arpgKit holds one controlsKit. The files that name controlsKit are re-derived against it; current engine library. No interactKit code changed.
  • 1.6.3: Built against the current controlsKit (1.3.1) and pickupsKit 2.3.11 with its current SecondWind, juiceKit, MatchFlow and Lifeline, and the current engine library, so a world that installs interactKit beside cropsKit, economyKit or inventoryKit holds one release of each. No interactKit code changed; the suite runs 97 of 97.
  • 1.6.2: Built against controlsKit 1.2.8, the release every package that ships with sideScrollerKit moves to together, so a world installing them holds one controlsKit. Nothing plays differently from 1.6.1.
  • 1.6.1: Built against juiceKit 1.2.10 and controlsKit 1.2.4, so an install no longer carries older copies of them. Nothing plays differently from 1.6.0.
  • 1.5.4: The gallery's two big signs showed 1.5.1, because the gallery loads from its saved scene and that was not saved again when the version changed. Now the signs show this version, the gallery rewrites them from Interact.VERSION every time it loads, and a new test fails if the saved signs name any other version. Nothing else changes. 93 tests.
  • 1.5.3: Text only. The README's opening paragraph, which ZeroMind shows as the package's description, now names everything the kit gives you (chests and other containers, trigger zones, prompt styles, the six looks, sounds, multiplayer, the two guides) and how to install it. The gallery scene, the looks module and the Door, Switch, Container and Item descriptions say six looks instead of three; the package description says trigger zones. Nothing plays differently from 1.5.2. 92 tests.
  • 1.5.2: The README's opening list says 6 looks, as the kit has since 1.5.0 (it still said 3). Nothing plays differently from 1.5.1. 92 tests.
  • 1.5.1: Guide fixes from following both guides word for word in a new world with 1.5.0 installed from ZeroMind. The example's talking control file now has one control of its own, Esc to walk away from the conversation, because a control map with no controls cannot be switched on: with 1.5.0's text the hotbar still moved when 1 to 3 picked an answer. Now it does not, for each player on their own engine. The how-to's Build a room calls its walls warm grey, as they look. Nothing in the kit plays differently from 1.5.0. 92 tests.
  • 1.5.0: More looks, doors that fit your walls, sounds. Three new looks, dungeon (grey oak, stone frames, rusted iron, torch light), neon (gloss black with magenta and cyan light) and royal (ivory, marble and gold), for every door, switch, lock, container, item and the barricade, still picked with one look field; the gallery's right wing shows all six side by side. A door's stonework now takes the material and colour of the wall it is set into by itself (new Door field matchWalls, on by default; wallMaterial still wins), so doors in your own walls no longer show grey panels; the README, the how-to and the example say so where you first place a door. Sounds, which the kit had none of: doors (wood, heavy gate, sci-fi slide), levers and buttons, chests, unlocking and a locked rattle, pick-ups and the barricade's hammer, played on each player's own engine (new Interact.sound, Interact.SOUNDS, setSoundVolume, getSoundVolume and InteractSettings soundVolume). A portcullis or garage door shakes the camera only of players near it, not the whole level. The how-to guide opens with Build a room, step by step (walls, a door in them, a lever, a chest that hands out the next door's key, a hold-to-open chest, a bag and a character who talks, each with what you should see); the example guide adds checks after its build steps, and its conversation now holds a talking control file so pressing 1 to 3 picks an answer without also moving the hotbar. Gallery: the title shows the version, and the rows of labels no longer crowd each other from the spawn. 92 tests.
  • 1.4.5: The first release of 1.4.3 and 1.4.4 below, contributed by a user of the kit (pull request #2); installs go from 1.4.2 straight to 1.4.5. On top of them: the gallery scene is re-baked so its boards are stored with the linear tints its build now makes (new installs load the baked scene); the README and package.yaml name the 90 tests the suite runs; the Door component's README names wallMaterial. Nothing plays differently from 1.4.4.
  • 1.4.4: Doors fit into your own walls. New Door field wallMaterial: the door's stonework (the wall pieces beside the frame, and a portcullis's stone jambs and gatehouse, which it always builds) wears that material instead of the look's plain stone colour, so a door set into a textured stone, brick or plaster wall matches it. The README and both guides now say how to set a door into your own walls (wall = 0 and a doorway cut to the frame, or wall plus wallMaterial). One new test (90). Builds on 1.4.3.
  • 1.4.3: The three looks now show the colours their palette names. The palette is written as sRGB hex (as a colour picker shows it) but was handed straight to the Model tint, which takes linear light, so every look rendered washed out: the wood chest read as pale cardboard with light grey straps instead of dark planks with black iron straps, and scifi and cartoon were paler than designed too. Looks.paint and Looks.tint now convert to linear first (new Looks.linear(hex); Looks.rgb still returns the sRGB values), and the gallery boards do the same. Nothing else changes: kinds, fields, wiring and prompts play as in 1.4.2.
  • 1.4.2: Fixes from playing the guides. A label set on the Interactable beside a device is now what its prompt says while it is closed or off (the example's chest said Open chest instead of Heave open). A hold prompt now says Hold to use under its action, and letting go before the bar fills shows Keep holding until the bar fills, so a tap no longer looks like nothing happened. New onPlayer = true for setInventory: interactKit runs give on the engine of the player who gets the item, exactly once, so an inventory each player keeps on their own engine (inventoryKit's bag) needs no messages of its own; the guides use it, and the second player in the example no longer risks getting items twice. README and example: the quick start's lever is on your left and the chest on your right, the example's lever on the left and crate on the right, as seen from the player; the example names the version it was checked with, and its two-player notes say what really happens. 89 tests.
  • 1.4.1: Text only, nothing plays differently. The README's Guides section is shorter: the two guide names, where they live and how to open them. No em dashes in the package's code comments, scene scripts or text. The gallery is re-baked by the current engine, which records its components by their full names (interactKit.Door). 86 tests.
  • 1.4.0: Guides. Two guides now ship inside the package: How to make doors, switches, locks and chests (every part of the kit, written the way people search for it) and Example: an escape room puzzle with switches and locked doors (an empty world to a treasure vault with inventoryKit and dialogueKit, followed word for word in a new world, alone and with two players). README: a Guides section saying how to open them, the family of kits with links, a recipe for keys in inventoryKit's bag, known limits that each name an open issue, and no em dashes. One new test checks the guides ship and link each other (86). No change to how anything plays.
  • 1.3.2: Faster with many usable things. Each frame the prompt HUD merged the settings and asked the status of every usable thing in the world, however far away; with a few hundred (a farm with a prompt per plant) that cost about 5 ms a frame. It now remembers how far each thing can be in focus and skips the far ones with one distance check, so the cost follows what is near the player. Prompts, focus and ranges are unchanged.
  • 1.3.1: Fixed: picking anything up made the game heavier and heavier. A taken item rebuilt all its parts every frame on every player's machine; because they hang under a shared object, that also flooded the network, so a second player fell further behind and saw doors open late or never, and could be told "already taken" for their own key. Items now build their shape once and hide with a single change; a taken item costs a clock check per frame. The player who walks over an item sees it go at once, and their own repeated grab never brings it back. The carried-items strip re-reads the inventory a few times a second instead of every frame. Two-player checks through the kit's network handler: each player keeps their own key, the key door opens for the holder and refuses the one without, a chest two players open in the same frame opens once, and every coin goes to exactly one player.
  • 1.3.0: Fixed: in a world with only interactKit installed, walking over the quick start's key did nothing, because the key was a pickupsKit pickup and pickupsKit's components cannot load from /source/deps/. Keys, keycards, coins and gems are now interactKit's own Item component, counted per player in interactKit's own shared inventory; containers spill Items; each player sees what they carry in a strip at the top left once they carry something. interactKit no longer depends on or names pickupsKit, so installing it brings only controlsKit and juiceKit (Interact.pickups is gone; setInventory connects any other inventory). New Interact.items, catalog family item. Gallery relaid out so every label reads from the spawn point, in the editor (which now opens on that view) and in play, with no label under a station's own prompt; its key and keycards are Items and the pickupsKit counter panel is gone.
  • 1.2.2: Web build hardening. Every timer (hold claims, auto-close, button pop-up, messages) now runs on getTime(), the wall clock, instead of os.clock(), which is CPU time and drifts in the browser, and would disagree between a desktop host and a web player. controlsKit's glyphs load on first use, so a dependency still downloading in a web build cannot take the kit down; prompts draw a plain lettered keycap until it arrives.
  • 1.2.1: Fixed: with only interactKit installed, its dependencies land under /source/deps/, where the folder paths it used (@root::controlsKit.prompts, "interactKit.Door") did not reach them. Dependencies are now loaded by package name (~controlsKit.prompts) and components by resolved type (Interact.component("Door"), new). The quick start uses require("~interactKit.api").
  • 1.2.0: Interact.spawnKey (keys and coloured keycards without knowing pickupsKit item names), so the quick start needs only interactKit. Full API reference. Tests cover every public call (68).
  • 1.1.0: InteractSettings: the world's prompt style in one field. Fixed a turned airlock's halves blocking its doorway; the bookcase opens to 90°. Keyboard, gamepad and touch verified for press and hold.
  • 1.0.0: first release.

Dependencies

Installed with interactKit:

  • controlsKit 1.2.8: button-prompt glyphs.
  • juiceKit 1.2.10: open / close feedback.

Not a dependency any more: pickupsKit. Up to 1.2.2 interactKit used its pickups for keys and loot, but an install puts pickupsKit under /source/deps/, where its Pickup components cannot load their own code, so keys never counted in a fresh world. interactKit's own Item replaces them, and interactKit no longer names pickupsKit anywhere, so an install does not bring it along. To have pickupsKit's counters open interactKit locks in a world that has pickupsKit installed at the top, see setInventory under API.