Pop Goes the Chicken
You need to reach the space station, but the launch pad is out of action. And look at all those chickens...
Controls
- X to jump
- Left/Right to direct your jump
Also on itch.io: https://ggaughan.itch.io/pop-goes-the-chicken
In what situations do you use these conversions?
hexnumber = '3xz' --A tonum(hexnumber,1) : 768 (0x0300.0000) --B tonum("0x"..hexnumber,4) : 0 (0x0000.0000) --C tonum('0x'..hexnumber) : -- NO VALUE --([nil]) |
Example
I want "nil" to be returned when I use a character as an identifier. Therefore, I use the "C" conversion.
hexstr = '108000789$' hexval = TONORM(hexstr) -- Normalize the value [number boolian nil], otherwise it remains a string. hextable = {} if type(hexval) == 'string' then foreach(split(hexstr, 3), function(v) add(hextable, tonum('0x' .. v)) end) end -- Handle hexadecimal conversions without being converted to numbers by normalization. -- Only the value of number is stored in the hextable. -- "$" is not stored. |
here's a demo cart showing off some different ways to handle input in grid-based games:
controls:
- move around with the arrow keys
- change "chapters" in the pause menu (enter + arrow keys)
- slow down the game speed (in the later chapters) in the pause menu
I made this cart as a companion to a blog post about input buffering
I am playing around with the wander demo so I can experiment with y axis movement to make a beat em up style game but i still want to be able to jump (in cases to dodge and platform in certain sections)
Here is the code if any of you are wondering:
function _init()
x=24 y=24 -- position (in tiles)
dx=0 dy=0 -- velocity
f=0 -- frame number
d=1 -- direction (-1, 1)
acc=0.5
boost=.5
end
function _draw()
cls(1)
-- move camera to current room
room_x = flr(x/16)
room_y = flr(y/16)
camera(room_x128,room_y128)
-- draw the whole map (128⁙32)
map()
-- draw the player
spr(65+f, -- frame index
x8-4,y8-4, -- x,y (pixels)
1,1,d==-1 -- w,h, flip
)
end
function _update()
ac=0.1 -- acceleration
if (btn(⬅️)) dx-= ac d=-1
if (btn(➡️)) dx+= ac d= 1
if (btn(⬆️)) dy-= ac
if (btn(⬇️)) dy+= ac
-- move (add velocity)
x+=dx y+=dy
-- friction (lower for more)
dx =.7
dy =.7
-- advance animation according
-- to speed (or reset when
-- standing almost still)
spd=sqrt(dxdx+dydy)
f= (f+spd*2) % 4 -- 4 frames
if (spd < 0.05) f=0
-- collect apple
if (mget(x,y)==10) then
mset(x,y,14)
sfx(0)
end
end
I wanted to add something along the lines of
--jump
if (btnp(x)) then
player.dy=player.boost
Am I missing something?
2 Knights
WIP of an arcade game I'm making with my kids.
Find the key in each room and carry it to the door to move on. Defeat all enemies in the room before moving on to find treasure, but don't stay around too long...
Controls
- Arrow keys: move
- Z: jump
- X: attack/throw key
- UP + attack: pick up/drop key
I'm making a serious effort to create a PICO-8 version of Sid Meier's Civilization. This is a challenge because the rules are complicated but I'm having fun and that's the primary reason to do anything.
Changelog
v0.6
- Options menu
- Initial city manager implementation
- Implemented unit production selection
v0.5
- Added units: Cannon, Chariot, Armor, Mech.Inf, Artillery, Sail
- Added black border to cities that contain a unit
- Minimap shows explored map, cities, active unit
- Implemented tribal/goody hut
- Show player gold
- Fixed movement stuck bug
v0.4
- Added units: Musketeers, Riflemen, Knights, Catapult
- Fixed double movement bug
Hello all
New here.
I just started with PICO-8 and learning LUA 2 days ago.
I made a demo of Mars defender... Code needs cleanup and I'm not finished yet but it works pretty well for the time being.
Hope you like it! :)
UPDATE 04.03.2022: Release version 0.9. Changed year (yep we're indeed in 2022 :D) and created an endboss. Fixed various bits and bugs. Game is small with only 5 but I don't see the point in going for 100 waves.
UPDATE 24.02.2022: Changed the name. A few tweaks and bugfixes, faster response, graphics and particle explosions.
Worked on various game mechanics, player energy and collision, AI for the Aliens etc.
I made this for use myself, because i couldn't find anything for this specific purpose. Thought I'd post it here in case anyone else gets some use out of it.
It converts a list of variables in the following format to a version optimised for tokens:
-- input t=0 cam_x=0 cam_y=0 shake=0 floor=1 gold=0 current_music=-1 mode="splash" title_s=1 lastdist=0 fadepos=0 -- output t,cam_x,cam_y,shake,floor,gold,current_music,mode,title_s,lastdist,fadepos =0,0,0,0,1,0,-1,"splash",1,0,0 |
To use it, paste the original variables into the cart and it will output the "crunched" version out to the clipboard.
Bit of a warning though, this format gets unreadable fast.
It also seems (in most cases) to work if some of the values are already in this format as it simply pairs what's before the equals with what's after, e.g.:
-- input t=0 cam_x,cam_y=0,0 ey,et=256,0 shake=0 -- output [ [size=16][color=#ffaabb] [ Continue Reading.. ] [/color][/size] ](/bbs/?pid=107532#p) |
Wumple
A short arcade game thingy that kinda was a mash of Pacman and adventures of Lolo. Made for ToyBoxJam 3.
One day at work a mother comes in and says she's lost all 40 of her kids and 'requests' help. Dodge toasters, Snakes, and more and make your way back home.
Made by SmellyFishstiks
Pathfinding help from Luchak
Made for Toy box jam 3 (https://itch.io/jam/toy-box-jam-3)
changelog
V1
- released
V2
- Fixed stacked comment blocks crashing the game
- Fixed crash occurring when actor tried to find a path and returned a #path of 0
- Fixed Rescue ship not being centered when flying away
- Fixed Wayback-Final having a time limit and thus a ghost that could force you to reset your score if it ate grifert
My entry for Toy Box Jam 3, 2022. Help Sally Neptune escape from the evil Monocronies!
- Move: arrow keys
- Shoot and strafe: X. This will strafe if you are not targeting something, and will let you circle-strafe a target.
- Jump: Z or C
- Tips:
- You will need keys to open doors.
- Look for the giant Neptune coin to escape!
- There are gun powerups around that will let your rainbow gun shoot faster. Try to find them all!
I've always wanted to make a game based on the cast.p8 demo, and this is it! I am very happy with how sprite occlusion turned out.
I wrote this game in multiple files, so it may be tough to read in the pico8 editor. When I get a repo up on github, I'll update this in case anyone wants to see how I made this. Enjoy!
Hi, this is my first Pico-8 game. It's a remake of the Dreamcast game ChuChu Rocket. This is a multiplayer game, best played with 2 controllers. The game contains 16 levels.
I've tried to make the code easy to follow so others can examine it and learn the techniques.
Instructions
Use the arrow keys to move your cursor.
Press the O button and a direction to place an arrow on the grid. Mice and cats will follow the arrows.
Steer the mice into your rocket (the red or green circle), and steer the cats into your opponent's rocket.
Mice score 1 point, or 50 points for a gold mouse. Cats remove 1/3 of your total score.
The round ends after 3 minutes and then moves to a new random map.