How we test

Every machine on Contraptify runs in a simulator that follows Java Edition 26.3's own redstone rules, with the game's default settings: block update order, scheduled ticks with priorities, piston timing, quasi-connectivity and torch burnout. Your AI writes a test for each machine from what you asked for: what a player does and when, and what must happen then. The simulator runs it tick by tick and reports what holds and what doesn't, and the AI fixes the design until it all holds.

339 reference tests

Each test builds a small circuit and checks the simulator against known game behaviour. All of them pass on every change before it goes live.

Dust strength 5

  • dust next to a lever is 15
  • loses one level per block
  • 16th dust is 0
  • dust has no delay (same tick)
  • turns off at once

Weak and strong power 3

  • dust does not pass through a block it powers
  • a weakly powered block lights a lamp next to it
  • a strongly powered block powers dust next to it

Timing 6

  • repeater delay 1 turns on after 2 game ticks
  • repeater delay 2 turns on after 4 game ticks
  • repeater delay 3 turns on after 6 game ticks
  • repeater delay 4 turns on after 8 game ticks
  • a torch starts lit
  • a torch turns off 2 game ticks after its block is powered

Repeater locking 2

  • a locked repeater ignores its input
  • it catches up once unlocked

Transparent blocks 5

  • power climbs onto glass
  • but does not come down off glass
  • glass does not pass power to a lamp beside it
  • a solid block above the lower dust cuts the step up
  • glass above the lower dust doesn't cut it

Torch burnout 4

  • a fast torch clock burns out
  • and stays off while burnt out
  • with no block update it stays out (its own update took the place of the 160-tick recovery tick)
  • a block update relights it once its toggles are more than 60 ticks old

Pistons 17

  • a piston fires in the same tick it is powered
  • the pushed block is moving for 2 ticks
  • then lands
  • 13 blocks are too many to push
  • 12 blocks can be pushed
  • obsidian can't be pushed
  • blocks with inventories (dispensers) can't be pushed
  • dust in the way is broken
  • slime drags the blocks stuck to it
  • slime and honey don't stick to each other
  • piston leaves the block
  • sticky_piston pulls the block back
  • a lever on top of a sideways piston pops off when it extends
  • so does a torch on its side
  • a standing torch on top of it stays (it needs only the middle of the face)
  • a lever on its back stays while it retracts
  • and after it has retracted

Quasi-connectivity 4

  • BUD: the piston stays retracted after the lever is switched on
  • and extends as soon as it gets a block update
  • dispensers are quasi-connected too: no shot without an update
  • one shot after an update

Observers 3

  • an observer pulses for 2 ticks, starting 2 ticks after the change
  • an observer moved by a piston pulses once after landing
  • a sticky piston given a 2-tick observer pulse leaves its block behind

Flying machine 1

  • it flies and stays in one piece

Comparators reading containers 11

  • an empty chest reads 0
  • one item in a chest reads 1
  • a chest with 2 full stacks reads 2
  • a full chest reads 15
  • a full barrel reads 15
  • a trapped chest with 14 stacks reads 8
  • a hopper with 1 full stack reads 3
  • a dropper with 9 eggs reads 1
  • 16 eggs count as a full stack (a dropper with 2 stacks of eggs reads 4)
  • one sword fills a hopper slot (reads 3)
  • a comparator reads a chest through a solid block

Hoppers 12

  • a hopper pulls at once, then items move one hopper every 8 ticks
  • all three items arrive
  • items cross three hoppers in 8-tick steps
  • a hopper pushes from its first filled slot into the first slot with room
  • then into the next slot with room
  • a hopper does not push into a full container
  • a powered hopper is locked and moves nothing
  • unlocked, it pulls on the next tick
  • and pushes 8 ticks later
  • locked again, it holds
  • dust stays on a hopper and carries power
  • the dust on top locks the hopper

Droppers 8

  • a dropper moves one item 4 ticks after it is powered
  • a comparator reads the chest it filled
  • one item per press, and nothing once it is empty
  • a comparator reads 1 from a dropper with one item
  • the dropper throws its last item and the comparator turns off
  • the hopper passes a dropped item on 7 ticks after it arrives
  • a hopper next to a strongly powered block stays locked while the button is down
  • it unlocks when the button pops up

Trapped chests 2

  • dust connects to a trapped chest
  • a closed trapped chest gives no power (the lamp beyond stays off)

Pressure plates 14

  • stone_pressure_plate: a player on it gives 15 at once
  • stone_pressure_plate: it strongly powers the block under it
  • stone_pressure_plate: it checks every 20 ticks, so it lets go 15 ticks after the player steps off
  • stone_pressure_plate: the dust and the lamp turn off
  • wooden_pressure_plate: a player on it gives 15 at once
  • wooden_pressure_plate: it strongly powers the block under it
  • wooden_pressure_plate: it checks every 20 ticks, so it lets go 15 ticks after the player steps off
  • wooden_pressure_plate: the dust and the lamp turn off
  • light_weighted_pressure_plate: one player gives power 1
  • light_weighted_pressure_plate: it checks every 10 ticks
  • heavy_weighted_pressure_plate: one player gives power 1
  • heavy_weighted_pressure_plate: it checks every 10 ticks
  • a player moving to another plate presses it at once
  • the first plate lets go at its next check

Target blocks 8

  • dust points into a target block
  • powered dust powers a target block like a solid block (the lamp beside it lights)
  • a thrown snowball has not hit yet
  • a snowball in the middle of a face gives 15 on the next tick
  • it is still on 7 ticks after the first hit
  • it turns off 8 ticks after the first hit, even after a second hit
  • the hit target gives 15
  • pushed by a piston, it lands without power

Daylight detectors 6

  • a daylight detector waits for the game time to reach a multiple of 20
  • then it gives the sky's power (15 at time 4300)
  • at time 3020 it gives 13
  • a right-click inverts it and it checks at once (0 by day)
  • inverted, it gives 11 at midnight
  • at dusk (13680) it gives 0

Tripwire 9

  • hooks facing each other with string between are attached
  • a player in the string powers both hooks at once
  • a powered hook strongly powers the block it hangs on (the lamps light)
  • the hooks stay on while the player stays
  • the string checks every 10 ticks, so the hooks turn off 5 ticks after the player leaves
  • a stone block in the line: nothing is attached
  • so the string doesn't power the hooks
  • string broken by a piston powers the hooks
  • 10 ticks later they are off and no longer attached

Lecterns 7

  • a comparator reads page 1 of 5 as 1
  • turning the page powers the lectern at once
  • it strongly powers the block under it (the lamp lights)
  • the pulse lasts 2 ticks
  • page 2 of 5 reads 4
  • the last page reads 15
  • past the last page nothing happens

Sculk sensors 40

  • a vibration travels 1 block per tick: not yet after 2 ticks
  • it arrives after 3 ticks: the sensor is active with power 10 (15 - floor(15 / 8 x 3))
  • a comparator reads the frequency: 10 for a lever turned on
  • it stays active for 30 ticks
  • then it cools down with power 0
  • the comparator reads 0 while it cools down
  • and is inactive again 10 ticks later
  • a lever turned off has frequency 9
  • 9 blocks away is out of range
  • 8 blocks away is heard, with power 1
  • of two vibrations in the same tick, the nearer one wins
  • a vibration on its way blocks later ones
  • the far lever's vibration arrives after 8 ticks, power 1
  • a lever out of range is not heard
  • a piston breaking a block gives a vibration there (block_destroy, nearer than the piston)
  • its frequency is 12
  • a piston retracting gives frequency 9 at the piston (power 8)
  • wool between a lever and a sensor blocks the vibration
  • wool next to the line does not
  • two wool blocks that meet at the line's corner block it
  • one of them does not
  • the near sensor hears the lever (power 2)
  • a sensor activating gives no vibration
  • a piston can't push a sculk sensor
  • an active sensor lights a lamp above it and one beside it
  • it strongly powers the block it stands on (a lamp beside that block lights)
  • the dust behind it is at 9
  • it doesn't hear a button pressed (frequency 10)
  • it hears the button pop up (frequency 9), with power 14 (range 16)
  • a calibrated sensor stays active for 10 ticks
  • then cools down
  • it hears up to 16 blocks: 12 blocks gives power 4
  • it powers its sides, front and top
  • but not the block behind it
  • and strongly powers the block it stands on
  • a snowball landing on a target 3 blocks up: frequency 2, heard 3 ticks after the hit
  • switching a daylight detector: frequency 11
  • a player stepping on a pressure plate: frequency 10
  • tripwire: not yet after 4 ticks
  • the hooks 5 blocks away are heard (power 6)

Doors 14

  • the design's door is two blocks: a lower and an upper half
  • a lever opens both halves at once (no delay)
  • and closes them at once
  • an iron door doesn't open by hand
  • power beside the upper half opens the door
  • a player opens a wooden door
  • power on an open door: it stays open and is powered
  • a player closes the powered door (clicking the upper half)
  • power off: it stays closed
  • power on again opens it
  • dust ending beside a door powers it
  • an observer facing the upper half sees the door open
  • a piston breaks a door, both halves
  • a door powers nothing: only the door beside the lever opens

Trapdoors 11

  • dust stays on a closed top trapdoor
  • a lever opens a trapdoor at once
  • the dust on it drops off
  • it closes when the power goes
  • an iron trapdoor doesn't open by hand
  • a lever under a bottom trapdoor opens it, drops off, and the trapdoor closes again at once
  • a player opens a wooden trapdoor
  • and closes it while powered
  • the lever opens the trapdoor
  • pushed away from the lever it lands unpowered and closes
  • pulled back beside the lever it opens again

Fence gates 17

  • a lever opens a fence gate at once
  • and closes it
  • a player looking south opens a north gate away from them: it turns to face south
  • closing keeps the facing
  • looking across it doesn't turn it
  • a piston pushes a fence gate
  • a door opening 3 blocks away is heard: frequency 10
  • a door closing: frequency 9
  • a trapdoor opening 3 blocks away is heard: frequency 10
  • a trapdoor closing: frequency 9
  • a fence gate opening 3 blocks away is heard: frequency 10
  • a fence gate closing: frequency 9
  • a player opening a trapdoor: frequency 10
  • validation: a door needs the block above it free
  • validation: a door needs a full top face below
  • validation: a lever on a door is refused
  • validation: a door with a full block under it passes

Copper bulbs 8

  • power turns a copper bulb on at once
  • a comparator reads a lit bulb as 15
  • power off: it stays lit
  • the next power turns it off
  • and the comparator reads 0
  • a copper bulb is not a conductor: a repeater into it doesn't light the lamp beside it
  • a bulb can start lit
  • pushed next to a redstone block, it toggles off when it lands

Note blocks 11

  • power plays the note once
  • power off plays nothing
  • a player's click raises the note and plays it
  • after 24 it goes back to 0
  • high notes: 23, one click to 24, power plays 24
  • a note block is a conductor: a repeater into it lights the lamp beside it
  • with a block on top it plays nothing
  • a note played 3 blocks from a sensor is heard: frequency 10
  • a note block with a block on top plays no note: the sensor hears nothing
  • a copper bulb switching makes no vibration
  • an observer sees a note block's note change

TNT 12

  • unpowered TNT stays
  • power lights TNT at once: the block is gone
  • the lamp beside it stays dark (lit TNT powers nothing)
  • TNT on its way is not lit yet
  • TNT pushed next to power lights when it lands
  • lit by a lever pull it explodes 80 ticks later
  • lit through dust from a lever, also 80
  • lit by a repeater during a tick it explodes 79 ticks later
  • lit by a torch turning on, 79
  • lit by an observer, 79
  • lit by a piston landing it (after the entity phase), 80
  • a test checks up to the explosion tick (lit in tick 12, explodes in 91)

Crafters 16

  • a comparator reads a crafter's filled slots: 1
  • power sets it triggered at once
  • nothing crafted after 3 ticks
  • 4 ticks later it crafts one log into 4 planks, into the chest
  • it shows crafting for 5 ticks
  • then stops
  • the next pulse crafts the last log; the comparator then reads 0
  • a crafter is a conductor: a repeater into it lights the lamp beside it
  • no quasi-connectivity: power beside the block above it doesn't trigger it
  • each recipe crafts its result into the chest (no recipe: nothing; a disabled slot counts as empty)
  • validation: a hopper feeding a crafter is refused
  • validation: a torch on a fence post passes
  • validation: stairs with pistons are refused
  • validation: TNT and a pressure plate are refused together
  • validation: TNT and a sculk sensor are refused together
  • validation: a disabled slot can't hold an item

Building blocks 13

  • before the levers no lamp is lit
  • packed ice, soul sand and mud conduct; glowstone, sea lanterns, leaves, fences, walls and stairs don't
  • what stays on stairs facing north
  • what stays on stairs (top) facing east
  • what stays on fence
  • what stays on leaves
  • what stays on glowstone
  • what stays on soul_sand
  • a repeater can stand on a hopper
  • dust steps up past glowstone above it, but not past packed ice
  • validation: a dispenser with eggs and a sculk sensor are refused together
  • validation: a dropper dropping into the world and a sculk sensor are refused together
  • validation: a calibrated sensor needs a facing

Rails 28

  • no rail is powered before the levers
  • a powered rail line carries power 9 rails, in the same tick
  • an activator rail line does the same
  • a rail of the other kind stops the power
  • the whole line turns off at once
  • power climbs a slope
  • power runs down a slope
  • power from the lower rails doesn't reach a rail one block up
  • power from the upper rails stops at the step
  • a rail turned across the line stops the power
  • dust pointing into a powered rail powers it (and the next one)
  • the pistons have quasi-connected power but haven't moved
  • a powered rail turning on updates the blocks next to the block below it
  • a sloped one also updates those next to the block above it
  • the opened trapdoors leave the rails in place
  • a neighbour update breaks them
  • only the broken powered rail updates the blocks around the block below it
  • rails need a full top face below them (a hopper counts)
  • a sloped rail also needs a full top face on the block it rises toward
  • dust links to a detector rail only
  • validation: a straight rail line passes
  • validation: a rail needs a shape
  • validation: only plain rails curve
  • validation: a rail whose shape the game would change is refused
  • validation: a corner of plain rails passes
  • validation: a junction of plain rails passes (it switches with power)
  • validation: rails with pistons are refused
  • validation: a slope needs a block to rise against

Falling blocks 15

  • sand and gravel start to fall 2 ticks after the block below goes
  • they land after 8, 11, 16, 22 and 32 ticks for drops of 1, 2, 4, 8 and 16 blocks
  • a falling block lands on full tops, top slabs, stairs, fences, walls, leaves, hoppers, top trapdoors and sand
  • it breaks on bottom slabs, dust, torches, levers, rails, repeaters, soul sand, chests, honey and bottom trapdoors
  • the broken ones are logged
  • sand stays on a torch
  • a stack leaves from the bottom, 2 ticks apart
  • the stack lands as three blocks
  • the pushed sand falls 2 ticks after it lands and becomes a block on the floor
  • the observer sees the sand land
  • sand landing on a piston head that finished moving is followed
  • sand meeting a block the piston is still moving is flagged
  • validation: sand with a pressure plate is refused
  • validation: sand with a hopper is refused
  • validation: sand with a sculk sensor is refused

Minecarts 27

  • a minecart on a powered rail that is off stays put
  • the powered rail pushes it away from the block, east
  • it rolls about 7 blocks and slows to a crawl
  • the minecart goes down the slope and stops on the unpowered powered rail
  • nothing is flagged
  • it stops against the block (its side 0.49 from its middle)
  • the minecart goes round both curves and up the boosted slope
  • it stops against the block at the top
  • the launched minecart reaches full speed
  • it goes through the curve and the dip and turns both detector rails on
  • the detector rail turns on as the minecart reaches it and lights the lamp beside it
  • it stays on while the cart is on it and turns off at a 20-tick check after
  • the comparator behind it reads 0 from a plain minecart
  • a placed minecart turns the detector rail on in the next tick
  • dust beside it lights a lamp
  • a T-junction keeps its placed shape until a signal source next to it changes
  • powered it curves north, unpowered south again
  • the minecart takes the curve north
  • a 4-way crossing doesn't switch
  • a T-junction with a powered rail as its third rail switches
  • a minecart leaving the rails is flagged
  • validation: a minecart on a rail passes
  • validation: a minecart off a rail is refused
  • validation: minecarts with pressure plates are refused
  • a design's test can place a minecart on a rail (a detector rail then lights a lamp)
  • place_cart needs a rail
  • validation: rails on soul sand with minecarts are refused

Not simulated yet

Items lying in the world, double chests, footsteps and flying items, TNT explosions, minecarts off the rails or bumping into things other than full blocks, and mobs. Machines that need them can't be tested yet. Every reference test that a player can build is also run on a real 26.3 server, which must agree on every block and every container on every tick once the machine is built.