(01-02-20) If you just want to see it in action, try out the cart above and examine the source-code. For a more detailed demonstration including compression, try out the cart below this.
TO LOAD THIS CART in Pico-8, in immediate mode type:
load #sccm |
UPDATE (01-01-20) Removed all loose global variables.



SOLVED: See @samhocevar's solution. Thanks everyone who contributed answers !
It's a pretty simple question that may not have so simple an answer.
Is there a way I can declare locally global variables inside a function.
By this I mean I define variables inside a function that meet two states.
-
The variable is seen for the first time and is therefore initialized with a new value.
- The variable has been seen before and is NOT initialized but in re-entering this function it retains the same values it had before this same function was exited earlier.
I know I can simply declare global variables but what I wanted was to be able to retain values of simply named variables that might be just a single letter. Yet can only be seen and globally recognized by that local function.
Here is an example:
function _init() word={"one","two","three"} for i=1,#word do count(word[i]) end end function count(a) localglobal n=0 n+=1 print(n.." "..a) end |







Rescue helpless aliens from the moon!
This is my entry for the Toy Box Jam and my first game made with Pico8 ^_^
HOW TO PLAY:
- Use booster to ease your landing
- Try to save as many aliens as you can in 120 seconds
- If you save all of the aliens before time runs out, extra points are awarded
Let me know your best score in the comments ;)
Enjoy exploring the world of a vacuum cleaning bot :)
This is my entry for the toy box jam 2019. It took me way longer as expected but I'm really happy with the results :)
Launcher info:
Cart Full Name: Roombanator (Toy Box Jam 2019)
Alias on Itch.io it was submitted under: bttrs
Cart Name on Lexaloffle: roombanator
Itch.io link: https://bttrs.itch.io/roombanator


TO LOAD THIS CART in Pico-8, from immediate mode type:
load #mgst |
UPDATE (12-30-19): web address
Metal Gear Solid was an incredible and groundbreaking 3-dimensional stealth game for the Sony Playstation released in the states back in 1998. Not only was it an incredible and challenging game the graphics for its time were nothing short of miraculous if you didn't count Final Fantasy 7.

This then is my tribute to the opening story, where Snake has infiltrated the lower levels, made it to the elevator, reaches the top and is at a secret base in Alaska where he is contacted by CODEC which stimulates the small bones in his ear of his mission and target.



Hey, i'm new to pico 8, been really enjoying making games in it. I was wondering does anyone know if it is at all possible to release and sell pico 8 games on steam? even if through the usual methods such as steam labs. If not if anyone has any further knowledge around this subject it would be greatly appreciated. Thanks
My entry to the first #ToyBoxJam is, a PICO-8 remake of...
Alfredo's Stupendous Surprise!
(Originally created by Tom Hall & John Romero - for Softdisk Issue #98)
I made it as best as I could, within the jam limitations
(e.g. only using pre-defined assets!)
CONTROLS:
Choose options (when prompted) = ◀ / ▶
X or Z to Start/Select
GAME:
Alfredo's back in this PICO-8 remake, especially for #ToyBoxJam
and has he got a surprise for you! 🥳🎉
- Will Alfredo get to his house?
- Will he get to blow out the candles on his cake?
- Will he die in some horrible death?
- Play his latest adventure and find out!
Have fun & thanks for playing! 😁
Release History
- v1.0
- Initial Release
- v1.1
- FIX: Bug with 10 Ton weight (thx Tom!)
- FIX: Co-routine bug on last screen (thx again, Tom!)



Cart Full Name: Food Trail!
Alias on Itch.io it was submitted under: vapidvial
Cart Name on Lexaloffle: food_trail-1
Instructions:
Use arrows to move/interact and the X key to throw food(considering you already have some).
Food Trail! is a game where the player has to attract as many monsters as he can with food to follow him to their umm... ask the sad standing monster! You have to keep them full or else they may lose their way, indefinitely! Also, some monsters taste better than others, according to a particular individual, so choose your monsters wisely.
This is my entry for #TOYBOXJAM, hope you like it!


Made this minesweeper clone for my first cart as a familiarization exercise of sorts.
Menu Options
- Tagging with '?' is on by default but can be turned off if desired
- Mouse control is available; behavior should be an accurate facsimile of the original.
- Once enabled, buttons and mouse controls can be used interchangeably -- but not concurrently, to avoid ambiguity over what should happen if button presses and mouse clicks occur at the same time
Will remember your settings (using cartdata) if played in the console.
Controls
Cursor movement: arrow buttons.
Cursor can be moved while O/X buttons are depressed (as long as your hardware supports those keypresses concurrently).



So this is my toyboxjam entry. It's my first attempt at a jam and my first complete game. Kinda excited I must say :)
Let me know what you think.
Launcher infos:
Cart Full Name: Cecio of the Valley [ToyBoxJam 2019] / ID: #cecioofthevalley
Alias on Itch.io it was submitted under: damngoodcocoa
Cart Name on Lexaloffle: cecioofthevalley-0
Itch.io infos
https://damngoodcocoa.itch.io/cecio-of-the-valley
How to play:
- arrow keys: moves player around
- z: action key
- x: speed up texts
Have fun!



My submission for Tom's ToxBoxJam 2019. It was a lot of fun! In the end I neither had the time nor the tokens to do everything I wanted to. But hey, I got it done in time! Hope you enjoy.
Info for the Launcher:
Cart Full Name: Max [ToyBoxJam 2019] / ID: #ghostronaut_max_tbj2019-0
Alias on Itch.io it was submitted under: ghostronaut
Cart Name on Lexaloffle: ghostronaut




Years ago there were only a handful of personal computers out there. The Apple ][ computer is the one I especially remember fondly.
In this I have created the "Applecart." A series of programming events that take old Apple ][ games and refurbish them written in Pico-8. And it's not just by one person.
Every Sunday I have given my team a challenge to write a particular Apple ][ game as well as they can in Pico-8. The only stipulation is it must follow the flow of the original game and try to keep the original sound effects if at all possible. Although creativity is definitely encouraged.
For instance I had remembered one game that I played by reading it off of audiocassette that had a UFO that played a sound that got lower in pitch the lower to the screen it was and higher, the higher it was. It would randomly shoot out a laser and try to hit the player. So the challenge was to hit the UFO fast and hard before the timer gave out, and there were a few ways you could play.




TOY BOX JAM LAUNCHER
Here is the launcher for TOY BOX JAM!
All the games are here! Choose your cart with arrows then press X to launch it.
You can get back to the Launcher by pressing RETURN (Pause Menu) and choosing "Back to Launcher".
SHOUT OUT TO ZEP! His last minute heroics fixed some small issues and lets the launcher work perfectly! Thanks, Zep!
Have fun with the games/tech demos/stories/experiences!
Also, good things come to those who wait..... ;^)










FIRST GAME - DESTRUCTOID - WIP
+++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++




+++++++++++++++++++++++++++++++++++++++++++++++
You have 60 seconds to score as high as u can.
+++++++++++++++++++++++++++++++++++++++++++++++
My first game in Pico8. Made as a challenge from another.
Perhaps I will post more info later...



