Log inGet started
World

Mario Kart OrigoZ

Branchmain
Branchesmain
Commit9a3c94ad3e

README.md

items — the ? crates and the two things they hold

Every lap of every circuit has rows of floating ? crates on the racing line. Drive through one and the kart is armed with a Mushroom or a Feather; L uses it. Crates go dark for 8 seconds and come back.

FileWhat it is
game/items.module (game.items)The slice's read-back surface.
Items.componentOne instance, spawned by the module. Owns arming the crates, the roll, and both items.
ItemCrate.componentOne per crate: spins, bobs, watches for the local kart, and respawns.

Where the crates are

tracks.crates(id) gives the positions — rows of four along the racing line, 5 rows on a loop and 8 on the ribbon — and the slice re-arms them whenever the circuit changes.

The rules

  • A kart already holding something does not take a second crate.
  • Mushroom — Core.BOOST.mushroom (2 s) of boost, source "mushroom".
  • Feather — Core.FEATHER_LIFT of lift, then, the moment the kart is back on the ground, 2 s of boost with source "feather".
  • Both are boosts other than the drift one, so they cancel the off-track speed penalty while they run.

API

local I = Core.system("items")
I.arm("cheep")   -- arm this circuit's crate rows
I.use()          -- use what the local kart is holding
I.held()         -- what that is: "", "mushroom" or "feather"
I.count()        -- how many crates are armed