Your first cart

Five minutes from zero to a running sprite. No install — the studio is a web page; carts compile and execute in your browser.

  1. Open the studio. Click Studio in the nav, or use the button below to load the sprites tutorial cart directly.
  2. Browse the tabs. The tab bar is Cart | Code | Sprites | Sounds | Samples. Cart holds cart metadata plus the machine picker — pick M8 or GameTank here; it changes what the other tabs look like (see The GameTank machine for the full capability comparison). Code is the Forth source editor. Sprites is an 8×8 tile editor on M8, or a 256×256 sprite-sheet paint editor with PNG import/export on GameTank (walkthrough: Sprite sheets & blit). Sounds is the tracker (patterns + instruments). Samples only appears on GameTank carts — PCM sample import, a waveform editor with loop markers, and wiring samples into Sounds-tab instruments (walkthrough: Samples & sample instruments); M8 carts see a placeholder there.
  3. Edit and compile. Make a change in the Code tab and click Compile. Errors land in the console drawer at the bottom.
  4. Run. Hit Run — the preview panel runs your cart at 60 Hz. Stop silences audio and halts the loop.

Try it

( tut-sprites: draw sprite 0 at center, move with arrows )
variable x  64 x !
variable y  64 y !
: update
  0 cls
  2 btn if x @ 1 - x ! then  ( left  )
  3 btn if x @ 1 + x ! then  ( right )
  0 btn if y @ 1 - y ! then  ( up    )
  1 btn if y @ 1 + y ! then  ( down  )
  0 x @ y @ 0 sprite ;   ( tile=0  x  y  flags=0 )

Next: read the Forth reference to see the full word set, or jump to one of the tutorials.