CANVAS · ARCADE

Arcade scenes

Combine ordered primitives and elapsed-time motion to build a portable game-like scene without a JavaScript engine.

60 FPS CAP

Time drives velocity

Frame rate changes redraw cadence, never the logical speed of a command.

ADVANCED EXAMPLE

Layer a starfield, hazards, and a player ship

Small stars and large hazards wrap at the logical scene boundary. The ship stays anchored while pulse motion animates its body and engine.

dowe
signal gameScene value:[
  { type:"circle" x:520 y:240 radius:3 fill:"backgroundText" motion:{ vx:-35 wrap:true } },
  { type:"circle" x:540 y:80 radius:28 fill:"danger" motion:{ vx:-54 rotation:24 wrap:true } },
  { type:"polyline" points:[{ x:90 y:180 } { x:38 y:210 } { x:54 y:180 } { x:38 y:150 }] closed:true fill:"primary" motion:{ pulse:0.7 } }
]

Canvas scene:gameScene viewWidth:640 viewHeight:360 fps:60 autoplay:true label:"Animated orbit scene" w:"full" h:96

MOTION MODEL

Compose motion fields deliberately

vx and vy

Translate the command origin in logical units per second.

rotation

Rotate a command by degrees per second around its origin.

pulse

Oscillate opacity without mutating the retained scene Signal.

wrap

Return translated origins through the opposite scene boundary.

BOUNDARIES

Keep game systems outside the renderer

Canvas renders retained commands and normalized input. Physics, collision detection, gamepads, audio, WebGL, shaders, and 3D engines are outside the current contract.