Log In  

Just something interesting I discovered this morning (01-26-22) while working on other code.

You can type in something like FUNCTION, FOR/DO, or IF and when you come to the end where you are ready to press ENTER, instead press SHIFT+ENTER. The IDE will automagically type in END for you aligning where you typed the previous statement. How cool is that ?

I checked also, it is not listed in the help file found HERE:

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

This also works for REPEAT/UNTIL, and WHILE.

P#105673 2022-01-26 16:19

This was added in 2020 with the release of 0.2. It's mentioned in the release post. It used to be just a shortcut for adding an indent and subsequent END, but starting in version 0.2.2b, it was made to be smart about its behavior based on the code on the line you're activating it from.

P#105679 2022-01-26 16:46

Whatever it is, it's awesome, @MBoffin ! I know GFA had something like this years ago but only spanned to a few commands, not all of 'em. Just another reason to love Pico-8. :)

Now if we can get folded functions like GFA could do - that would also be beneficial.

P#105681 2022-01-26 16:55

[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2024-04-19 13:31:47 | 0.008s | Q:11