Skip to content

Editing Tools Code Editor

THE_ORONCO edited this page May 19, 2022 · 1 revision

Code Editor

Hold shift to select (or click and drag with mouse)

keys description
CTRL-X, C, V to cut copy or paste selected
CTRL-Z, Y to undo, redo
CTRL-F to search for text in the current tab
CTRL-G to repeat the last search again
CTRL-L to jump to a line number
CTRL-UP, DOWN to jump to start or end
ALT-UP, DOWN to navigate to the previous, next function
CTRL-LEFT, RIGHT to jump by word
CTRL-W,E to jump to start or end of current line
CTRL-D to duplicate current line
TAB to indent a selection (shift to un-indent)
CTRL-B to comment / uncomment selected block

To enter special characters that represent buttons (and other glyphs), use SHIFT-L, R, U, D, O, XThere are 3 additional font entry modes that can be toggled:

keys description
CTRL-J Hiragana type romaji equivalents (ka, ki, ku..)
CTRL-K Katakana + shift-0..9 for extra symbols
CTRL-P Puny font hold shift for the standard font

By default, puny font characters are encoded as unicode replacements when copying/pasting, and both upper and lower case ASCII characters are pasted as regular PICO-8 characters. To copy/paste puny characters as uppercase ASCII, make sure puny mode (CTRL-P) is on.

Code Tabs

Click the [+] button at the top to add a new tab. Navigate tabs by left-clicking, or with CTRL-TAB, HIFT-CTRL-TAB. To remove the last tab, delete any contents and then moving off it (CTRL-A, DEL, CTRL-TAB)

When running a cart, a single program is generated by concatenating all tabs in order.

Code Limits

The number of code tokens is shown at the bottom right. One program can have a maximum of 8192 tokens. Each token is a word (e.g. variable name) or operator. Pairs of brackets, and strings each count as 1 token.
Commas, periods, LOCALs, semi-colons, ENDs, and comments are not counted.

Right click to toggle through other stats (character count, compressed size). If a limit is reached, a warning light will flash. This can be disabled by right-clicking.

Clone this wiki locally