Log In  

PICO-8 User Manual

PICO-8 v0.2.4c
https://www.pico-8.com

Author(s)


Joseph White // [email protected]

Edited by

@DOJI13

PICO-8 is built with:

SDL2 http://www.libsdl.org
Lua 5.2 http://www.lua.org // see license.txt
ws281x by jgarff // see license.txt
GIFLIB http://giflib.sourceforge.net/
WiringPi http://wiringpi.com/
libb64 by Chris Venter
miniz by Rich Geldreich
Latest version of the OG manual (as html, txt) and other resources:

https://www.lexaloffle.com/pico-8.php?page=resources

▨ Welcome to PICO-8!


PICO-8 is a fantasy console for making, sharing and playing tiny games and other computer programs. When you turn it on, the machine greets you with a shell for typing in Lua programs and provides simple built-in tools for creating sprites, maps and sound.

The harsh limitations of PICO-8 are carefully chosen to be fun to work with, encourage small but expressive designs and hopefully to give PICO-8 cartridges their own particular look and feel.

▨ Specifications


Display: 128x128, fixed 16 colour palette
Input: 6-button controllers
Carts: 32k data encoded as png files
Sound: 4 channel, 64 definable chip blerps
Code: Lua (max 8192 tokens of code)
Sprites: Single bank of 128 8x8 sprites (+128 shared)
Map: 128x32 8-bit cells (+128x32 shared)

❶ Getting Started

1.1 - Keys


ALT+ENTER: Toggle Fullscreen
ALT+F4: Fast Quit (Windows)
CTRL-Q: Fast Quit (Mac, Linux)
CTRL-R: Reload / Run / Restart cartridge
CTRL-S: Quick-Save working cartridge
CTRL-M: Mute / Unmute Sound
ENTER / P: Pause Menu (while running cart)
Player 1 default keys: Cursors + ZX / NM / CV
Player 2 default keys: SDFE + tab,Q / shift A
To change the default keys use the KEYCONFIG utility from inside PICO-8:

KEYCONFIG

1.2 - Hello World


After PICO-8 boots, try typing some of these commands followed by enter:

PRINT("HELLO WORLD")
RECTFILL(80,80,120,100,12)
CIRCFILL(70,90,20,14)
FOR I=1,4 DO PRINT(I) END
(Note: PICO-8 only displays upper-case characters -- just type normally without capslock!)

You can build up an interactive program by using commands like this in the code editing mode along with two special callback functions _UPDATE and _DRAW. For example, the following program allows you to move a circle around with the cursor keys. Press Esc to switch to the code editor and type or copy & paste the following code:

X = 64 Y = 64
FUNCTION _UPDATE()
IF (BTN(0)) THEN X=X-1 END
IF (BTN(1)) THEN X=X+1 END
IF (BTN(2)) THEN Y=Y-1 END
IF (BTN(3)) THEN Y=Y+1 END
END
` FUNCTION _DRAW() CLS(5) CIRCFILL(X,Y,7,14) END Now press Esc to return to the console and type RUN (or press CTRL-R) to see it in action. Please refer to the demo cartridges for more complex programs (typeINSTALL_DEMOS`).

If you want to store your program for later, use the SAVE command:

SAVE PINKCIRC
And to load it again:

LOAD PINKCIRC

That's it!

This is everything that I have painfully copied and pasted.
Now you can play some example games.

Hello


Cart #padizuduho-0 | 2022-08-11 | Code ▽ | Embed ▽ | No License


The first example game.
In my opinion, it looks really cool.

API


Cart #zagohuniwe-0 | 2022-08-11 | Code ▽ | Embed ▽ | No License


The second example game.
Just spinning bunnies.

P#115581 2022-08-12 00:41

1

I think you are forgetting the most important link, @DOJI13.

The Pico-8 User Manual:

https://www.lexaloffle.com/dl/docs/pico-8_manual.html

P#115639 2022-08-12 06:13

[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2024-03-29 09:00:05 | 0.031s | Q:16