Hack all the terminals and defeat the boss.
This is my attempt at making a polished game in a week and a half, although it ended up being 2 weeks. I had to drop a few features I wanted to put in due to time, and code ended up getting a bit messy. Still, I'm pretty happy with how it came out.
The frame rate can drop sometimes, particularly in the later parts of the game when there are a lot of enemies around.
Removed a tiny amount of unused code and added as many comments as I could fit without going over compressed size.
Added the ability to swap jump and shoot buttons because the defaults felt awkward in gamepad. Also fixed a couple of minor audio bugs.
I´m new to pico 8 and I do my first steps in moving an sprite through an dungeon.
that works well, but i the sprite moves on and on while keeping the button pressed
I want to stop after moving one tile in the pressed direction
so for moving on and on you have to press the button over and over again
How can I do this?
I tried it whith
but it doesnt work
Thanks for help!!
I've got Pico-8 running nicely on my Raspberry Pi through Retropie/Emulation Station now, but there's one minor annoyance.
It's a bit of a faff to have to reach over to the keyboard to hit Ctrl-R to start a game or Windows+Q to exit back to ES. It'd be really handy to be able to map those commands to a couple of the spare buttons on my arcade stick.
I see there's a file called sdl_controllers.txt, containing the text // add SDL2 game controller mappings to this file, but that's ALL it says. There are no clues as to what it wants that file to contain in order to map anything. config.txt also includes these lines:
// Custom keyboard scancodes for buttons. player0 0..6, player1 0..5
button_keys 0 0 0 0 0 0 0 0 0 0 0 0 0
but again, heaven knows what that means. KEYCONFIG is no good, it only lets you redefine the two Pico controller action buttons, not the other ones on my arcade stick.
Can anyone help?
TO LOAD THIS CART in Pico-8, type:
Use the ARROW KEYS to navigate and the (O) key to flip back and forth between 2D stars and 3D stars.
Sphere Stars as I call them has always been something to elude me. While I spent literal months on and off years ago back in QBasic trying to reproduce the "bowl" effect, I was never entirely successful.
Thanks to @freds72 he showed me it is indeed possible to reproduce. And maybe that was the push I needed to try one more time using a method I knew would benefit me later.
What method is that you ask ?
I have remapped every single pixel on the screen to a circular bowl. So when you plot on the screen instead of a rectangle you are actually drawing in a bowl and you get that nice curved effect when you navigate around the 2D star array.
I first saw this animation on a NES cart called, "Star Voyager." I remember renting it at the time and being utterly fascinated with how the stars moved in it, even being late in returning it even though I had no idea how to play the game. :)
And now I have mastered it. So what's next ? Well since I finally have star movement code the way I want it I can start working on a good space-shooter game. I may even incorporate my HYPERSPACE effect as part of the game. :)
I don't know about anyone else, but I can never resist a proper Christmas game. So what better time to make a Christmas-themed pico-8 game?
In Last Christmas, you play Santa, desperately attempting to deliver presents during an apocalyptic meteor strike. Can you save Christmas and deliver presents to boys and girls before their homes are destroyed, or will you leave their final moments on Earth marred by disappointment, believing - as they face incineration - that they just didn't make the Nice List this year?
It's up to you. Don't let them down.
It seems a shame to leave ZEP's own marvelous JELPI sprites behind on just his opening demo cart, so I borrowed them for my latest game, Pico-8 Roadway !
Based upon the Atari 2600 game called FREEWAY:
To move the 1st player forward, press (O) or equivalent.
To move the 2nd player forward (if desired), press the 2nd player (O) key, usually TAB.
Uses my collision function:
Game saves CARTDATA high-score.
Note: if you have any suggestions or ideas on making improvements in this game, please let me know and chances are - it will happen. :)
TO LOAD THIS CART in immediate mode type:
I have need of this function for a different game I'm working on - so you get a chance to enjoy and make use of it for your own projects.
Today most games in Pico-8 use what is called a HIT BOX to determine if there is a collision between two objects. And while it works fairly well it is not entirely accurate.
For instance, you could have a comparison between two completely different sprites and the hit box area would either be too big where a collision occurs even if they are not touching, or the hit box could be too small where you must run right up against the target and even though you are touching it, it does not register.
While this is good enough for most games, let's take a rare example of a game called VENTURE.
Venture was a challenging and interesting game in that the very pixels made it difficult to complete a level.
You would navigate WINKY your player around opponents and when you shot them while they did die, they also disappeared slowly one pixel at a time.
If the player were to touch any side of a live sprite or even a single dot of the dead one, comparing by pixels, that would defeat the player and they would have to start the level over.
And if you got yourself trapped in a narrow corridor waiting for an enemy's pixels to vanish enough so you could get around, this unstoppable skull comes after you - so it was the player's mission to grab the treasures from each room and leave as quickly as possible, trying not to shoot the opponents especially if they were blocking a door or exit.
Please enjoy this fairly complex function I wrote to do true pixel collisions.
To my knowledge no such routine exists for Pico-8 nor has anyone written one so it is indeed useful for pixel-accurate sprite collisions.
Two sprites are compared in the quickest way possible by determining both size and shape, including for instance a check between 15x4 and 20x18 if you so desire. Every pixel is checked and it does it the quickest way possible as well by determining which sprite is the smallest and largest.
The function itself uses several arguments:
-- sh1=spritesheet source x -- sv1=spritesheet source y -- sx1=spritesheet size x -- sy1=spritesheet size y -- ph1=screen position x -- pv1=screen position y -- sh2=spritesheet source x -- sv2=spritesheet source y -- sx2=spritesheet size x -- sy2=spritesheet size y -- ph2=screen position x -- pv2=screen position y
In this demo code above, try going to the sprite sheet and changing the shapes of the sprites to see the collisions truly are being checked per pixel.
HOPE THIS HELPS !
Does anyone actually have this working? If so, can you just tell us in simple language what we need and where? This much-linked "tutorial" is completely incomprehensible to normal people https://www.lexaloffle.com/bbs/?tid=3935 and none of the others I've found are any better.
Here's where I'm at so far:
I've copied the pico-8 folder you get into /home/pi, since after much searching I eventually figured out that's where it was meant to go.
I've got a file in that /home/pi/pico-8 folder called +Start PICO-8.sh, whose contents are this:
#!/bin/bash pushd "/home/pi/pico-8" ./pico8 -splore popd
I have absolutely no idea what any of that means, I just copied and pasted it from some of the various gibberish tutorials.
I've added the following to es_systems.cfg:
<system> <name>pico8</name> <fullname>PICO-8</fullname> <path>/home/pi/pico-8</path> <extension>.sh .p8 .p8.png .SH .P8 .P8.PNG</extension> <command>/opt/retropie/supplementary/runcommand/runcommand.sh 0 "/home/pi/pico-8/pico8 -splore"</command> <platform>pico8</platform> <theme>pico8</theme> </system>
I've added a couple of game files (in .p8.png format) into the same folder, because I couldn't see anything telling the Pi to look anywhere else for them. (Though I put them in /home/pi/RetroPie/roms/pico8 as well just for laffs.)
And I added a theme in /opt/retropie/configs/all/emulationstation/themes/carbon/pico8, and an EMULATORS.CFG in /opt/retropie/configs/pico8, even though nobody mentioned doing one, just because that's what you do for every other emulator in Retropie and in case it helped somehow. Contents of the file:
pico-8 = "/home/pi/pico-8/pico8 %ROM%" default="pico-8"
Now when I boot EmulationStation the Pico-8 core shows up, but the only file listed is +Start PICO-8.sh. When I try to run it I get dumped back to the menu, with this RUNCOMMAND.LOG:
Parameters: Executing: /home/pi/pico-8/pico8 /home/pi/pico-8/+Start\ PICO-8.sh /opt/retropie/supplementary/runcommand/runcommand.sh: line 1002: /home/pi/pico-8/pico8: Permission denied
The permission settings for the pico-8 folder are 0755. One of the tutorials said something about "a+x" but I haven't a clue what that means, so I just checked all the X columns. When that didn't work I tried the blunt instrument of making it 0777 but it made no difference.
Then I tried changing the permissions on the pico8 executable file itself to 0777, and got this RUNCOMMAND.LOG instead:
Parameters: Executing: /home/pi/pico-8/pico8 /home/pi/pico-8/+Start\ PICO-8.sh /home/pi/pico-8/pico8: error while loading shared libraries: libwiringPi.so: cannot open shared object file: No such file or directory
I searched for that and eventually found out that I should be trying to install something called wiringpi, but when I tried that I got this:
And I'm wary of typing the suggested command because I haven't a clue what it might do.
All I want to do is run it like a normal ES core, with a list of "ROMs" (the .p8.png files) that run when I click them. Any useful thoughts gratefully received.
TO LOAD THIS CART in immediate mode type:
Use the arrow keys to navigate between the 8-images stored. Press (O) to turn on and off the status.
- Santa Claus
- Christmas Tree
- Jingle Bells
- Candy Canes
- Christmas Wreath (turned out nicely !)
- Gingerbread Man
Thought I would start a fresh tab for this new code. And there's quite a bit new about it.
While before you could guarantee a compression of 682-chars per picture, now it is based upon the cluster of pixels. So more black or white space means greater compression.
Also it no longer uses the Spritesheet even for temporary storage, it's all self-contained now.
Here is a slideshow using standard _init(), _update(), and _draw() to demonstrate it with the smallest picture being 438-chars and the largest being 592-chars.
And - I think this is as far as I can go in my coding with this particular method of picture compression. It was an interesting run, 2-weeks was it ? And I'm off to work on other things now.
You're the last mouse on Mouse Earth (which is just sewers, but with a nice name), and Mouse Earth (still just sewers) is about to get flooded by water! Will you escape the maze in time and protect the legacy of Mouse Earth? (sewers)
- cute mouse!
- procedurally generated levels! yes, exactly like that No Man's Sky game!
- cute graphics!
- maze-oriented gameplay! yes, exactly like that DOOM game!
- spooky music~
This is a small game that originally started as a submission for the 239th One Hour Game Jam, the theme of which was "Mouse Only", which is of course open to interpretation. I made the basic maze in 2 hours and then decided to take additional time (~8 hours) and make it a sweet little game. I really like the end result and I hope you do too, you lovely human you.
Unless you're a robot.
You lovely robot you.
You may yourself have experimented with the IMPORT ability for Pico-8 to import sprite sheets. However if you tried it inside your own code, it doesn't work, that is until your program ends.
So how can this be accomplished ?
Well first off understand the method I found only works for the IDE, that is, this will not work Online, offline Java or exported to an EXE/Mac. It only works in the IDE.
Here is the code:
-- the power of import -- written by dw817 (11-24-19) import "one.png" if sget(3,3)==0 then run"" end cls() ?[[ there are no sprites in this program. what you see was loaded from an external file. ]] for i=0,15 do spr(0,i*8,60) end repeat flip() until forever
Save that as IMP.p8 if you like.
What's happening here ? It's pretty tricky actually. The first thing I do is import a .PNG file sized 8x8-pixels. Naturally it doesn't appear so the next line is TRUE, that is, the pixel at coordinates 3x3 on the sprite sheet is black. So then I RUN the program AGAIN.
At this point the IMPORT is added so the next statement is false. Then just run the rest of the code to show the sprite got loaded.
Here is a sprite to work with. Save it as ONE.PNG. Have it in the same directory as your IMP.p8 file.
Run the code and you will see it will import it after auto-executing it a 2nd time.
If you're content with this then you can indeed IMPORT any number of sprites, 256-at a pop per imported 128x128 pixels .png file if you like.
Perhaps in future Pico-8 you can indeed IMPORT or EXPORT any sprite sheet at any time without such methods, but this is not the case currently.
HOPE THIS HELPS !
X to create a new seed, Z to grow it. Arrow keys do make it more or less gnarly, and the branches longer or shorter.
Was fooling around with generating trees for something entirely different, but thought this became fun enough to share.
I was trying out the one of the BBS carts in the Leapdroid for Windows. While running a cart does indeed go full-screen and put a nice control interface for touch-screen which does work BTW, the game screen itself flickers from sharp pixels to blurry pixels very nastily and seemingly randomly back and forth.
This does not occur with any other APKs I've installed.
Something else to consider.