Log In  

Total amateur at this.

KiloWar 1.0
by 2bitchuck

On the scale of important problems, I understand that this probably rates super low, but with the recent web player update, part of the start screen of one of my games has vanished. I'll show you what I mean. Here is the title screen of my cart as seen in the cover image:

And here is what you see in the current web player (0.2.1c.21):

The road that the cars are on is gone. This happens on both mobile and desktop.

I haven't updated the cart for about 3 months, and obviously I don't have this version to test with locally to see if it's something I need to change in my code to account for a feature change. I'm pretty sure that I'm the only one that plays my games, so not a huge deal for me personally, but I wanted to flag it in case this is happening to anyone else with a bigger audience.

P#86757 2021-01-24 22:34

Cart #appabode-0 | 2021-01-01 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

This is a PICO-8 remake of the Atari 2600 game Haunted House! Can you collect the 3 pieces of treasure and escape the house before losing all your lives or running out of matches? How quickly can you do it?

Use X/Z to light a match - be warned, it won't stay lit for long! You can't see treasure or keys without light, and you can't pick up what you can't see. The monsters in the house will pursue you and will blow out your match if they get close. If they catch you, they'll steal your key and treasure to hide them in the house again.

Use left & right arrows on the title screen to toggle match flicker on and off. If you are a player for whom flashing lights/colors can trigger seizures, you'll want to turn the flicker off.

This game was made for Toy Box Jam 2020! All of the sprite and sound assets were created by others and everyone in the jam uses the same assets to make their games. Info on the jam and credits for all the assets provided to the participants can be found on the jam's itch.io page.

A huge thank you to the following folks for some of the code used in the game that they generously released under Creative Commons licensing!

There are probably bugs, but I've played a fair bit without a crash, so that's something at least :). So let me know in the comments how you did - time, matches & deaths!

P#86002 2021-01-01 01:42 ( Edited 2021-01-01 01:44)

I have a weird thing going on that I'm 100% sure is because of something I'm doing wrong, but I can't quite figure it out. Hoping one of you will have some insight!

When I run my cart, I have a title screen music track that plays using music(X), then fades out using music(-1,500) when the user presses X/Z to start the game. There's an intro cut scene where a different track plays using music(Y) then fades out when that cut scene ends, also using music(-1,500). The user plays, there's no music during the game but there are a variety of SFX that play from time to time. When the user wins or loses, there's another cut scene that plays music(Y) - however, for whatever reason, it only plays one of the 2 SFX in the pattern this time around. When that cut scene is done, the user gets the score screen, which plays either music(X) or music(Z) depending on whether the user wins or loses, but again only one SFX in the pattern plays. The user can then press X or Z to go back to the title screen, and music(X) only plays one of the 3 SFX in that pattern.

I suspect that somewhere, something's not getting cleared from a channel and that's preventing the rest of the SFX from playing, but I am not sure how to figure out what I'm doing wrong or how to fix it. Is there any guidance anyone can offer from this vague description? This is for my Toy Box Jam game, so if I can't figure it out before the deadline, I may end up posting it with "broken" music and maybe somebody can help me figure it out from my specific messy code so I can fix it post-release :).

For TL;DR - the flow that leads to this condition is basically:

music(X) --title screen, plays all 3 SFX, player presses X/Z
music(-1,500) --fades
music(Y) --plays both SFX, fade starts when scene ends
music(-1,500) --fades

gameplay with various SFX but no music playing until lose condition

music(Y) --plays only leftmost SFX in pattern, fade starts when scene ends
music(-1,500) --fades
music(Z) --plays only leftmost SFX in pattern, player presses X/Z
music(X) --title screen, plays only middle SFX in pattern
P#85940 2020-12-30 19:36

Does anyone know if there are any good token optimization tutorials out there? Something like a collection of tips that show a suboptimal way of doing something and then demonstrate an optimized equivalent?

I'm about 25% through my latest game but about 60% through my token count already. Ordinarily I am much more inclined to finish functionality first and optimize/polish later, but in this case there is no way I will be able to finish if I don't clean up because I'll run out of tokens well before everything is in.

I suspect most of my problem is that I have a lot of tables and nested tables, like this:

-- this is 76 tokens total and I have a total of about 608 tokens worth of just these
ryl = (yl + (flr(yl/10)*1.5))*7.84

which I then refer to values of like this (adding another 26 tokens): sspr(oteam.rec.rec1.sx,oteam.rec.rec1.sy,sprw,sprh,oteam.rec.rec1.x,oteam.rec.rec1.y,sprw,sprh,oteam.rec.rec1.f)

There are obvious things I could do here, like shoving "oteam.red.rec1" into something more compact so it's a single token instead of 3 every time, but I'm hoping there are more "best practices" sorts of things folks could point me to for general token savings and more proper ways to deal with data structures like this.

P#83365 2020-10-26 15:04

Cart #memory_2bc-0 | 2020-09-26 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

I was working on a grid layout sector map for another project, but all I could think of was how the grid reminded me of the classic matching game Memory (or Concentration in some locales). So to get that out of my system so I could move on with my space game, I stopped and made a quick & dirty version of Memory.

Use the arrow keys to navigate the grid, X to flip a tile, Z to toggle show/hide the time clock (useful if you want to see how close you are to a personal best). When you match two tiles, they'll stay flipped. When you match all 16, the game is over! Try to see how fast you can match all 16 tiles. My personal best is 30 seconds, but I'm sure it can be done faster. I blame my arthritis for my performance :).

Unless there's a game breaking bug, I probably won't bother updating this. Like I said, this was mostly to get the thought of this game out of my head so I could keep making the game I'm actually trying to make! This was a fun diversion for a few hours though, and even though some of the sprites are hot garbage, I'm pretty fond of some of them (the snake, one-eyed demon head, and spider crab).

P#82286 2020-09-26 03:28

Cart #kilowar-5 | 2021-01-29 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

v1.0 - Played through about 200 matches (seriously) to find and fix the last couple of bugs hopefully (a race condition on coup fourré where you could end up with 8 cards in hand, hear the coup fourré sound, but not actually get the coup fourré and a condition where CPU could run out of cards first and leave the player unable to play or discard, thus effectively stopping the game). I had originally planned to update the sprites, but I honestly like them as is, so I'm keeping them!

v0.9.2 - Bug fixes related to end game no-winner nil conditions where player runs out of cards before CPU because player played one or more safeties after the deck ran out.

v0.9.1 - Fixed unchecked nil bug in case where CPU gets coup fourré with the emergency card and also has a Go card in hand (obscure devil of a bug!)


Hello everyone!

I made a PICO-8 version of the classic French car racing card game Mille Bornes! This is a game I've probably played thousands of times in my life from childhood through . . . not childhood (age is just a number, but it's a BIG number!)

In the game, you race against a CPU opponent to be the first to reach 700km (or, if you feel daring, extend the race to 1000km for a chance at bonus points). In addition to 1 point per km, you gain bonuses for playing safety cards, getting coup fourré (playing a safety card as the corresponding hazard is being played against you), winning a race without playing any 200km cards, extending to 1000km, winning after the deck has been emptied, and shutting out your opponent. You race until someone totals 5000 points and wins the match! You can see the cards and a brief rules description by pressing z on the start screen.

During the game, left & right arrows let you select a card to play or discard. x plays a card, z discards. The up arrow lets you play coup fourré if CPU plays a hazard for which you have the safety card. But be quick! You only have a short time to perform the coup fourré while the indicator flashes.

EDIT: I realized that the rules can be cumbersome to figure out if you've never played before. The Mille Bornes Wikipedia entry is actually a pretty good reference for the game rules.

This game is a lot of firsts for me: my first PICO-8 program, first experience with Lua, the first game programming of any kind I've done, first pixel art (quite obvious), first music composition (SUPER obvious). I'm proud of having created a fun, playable game, but it's very much the work of a game programing beginner, so don't expect highly optimized code or probably any techniques you should emulate :). I had 319 tokens left at the end and I'm sure there's plenty I could have done more efficiently.

Special thank you to @Krystman, whose Breakout tutorial was my impetus to give this a go, and from which tutorial I shamelessly grabbed the sash code to use for coup fourré. And thanks to everyone in this community. I think this is my first post, but I lurk & read the posts here frequently, amazed at all the cool ideas you all have and how willing you are to share your knowledge.

P#81787 2020-09-14 02:24 ( Edited 2021-01-29 18:22)

Follow Lexaloffle:        
Generated 2021-05-17 22:50:36 | 0.115s | Q:25