Show HN: Driftmania – an open source PICO-8 racing game
276 points| frenchie14 | 2 years ago |frenchie14.itch.io | reply
The source code for the game is over here: https://github.com/maxbize/PICO-8/tree/master/Driftmania. It's a bit of a mess, but I'm happy to answer any questions on it or development of the game. Cheers!
EDIT: For those not familiar with PICO-8, there's only a few inputs: arrow keys, Z/C/N, and X/V/M
[+] [-] lagniappe|2 years ago|reply
https://powkiddy.com/products/pre-sale-powkiddy-rgb30-rk3566...
Non affiliated with the company, I get nothing from saying this, it's just a decent device all around. The 1:1 aspect ratio on the screen really does PICO-8 games justice, along with MAME and other popular platforms. The greatest thing is these devices are super cheap and easy to come by if you're patient.
Here's a video review of it by a youtuber whose opinion I've come to respect https://www.youtube.com/watch?v=LIMepWAzUuw
[+] [-] toastercat|2 years ago|reply
In comparison, Anbernic and Retroid sell devices with better build quality and slightly better QC.
[+] [-] frenchie14|2 years ago|reply
[+] [-] blacksmith_tb|2 years ago|reply
[+] [-] unknown|2 years ago|reply
[deleted]
[+] [-] sahara|2 years ago|reply
To be clear, I'm ultimately glad I bought it, and it's germane to this discussion that the release of the RGB30 is what got me interested in PICO-8 in the first place (I had apparently purchased a license years ago as part of the Bundle for Racial Justice and Equality on itch.io and didn't even realize it until late last year). Also, the 720p 1:1 display is one of those developments that in retrospect feels so perfect for this form factor it ought to have been obvious, but it was a weird move at the time and they deserve full credit for taking the risk.
Having said that, I want to love this thing, but I just can't. Mainly because the D-pad sucks. It's not unusable, but it's worse than my Miyoo Mini and Anbernic devices, worse by a mile than my 8BitDo controllers, worse still than my Hori Fighting Commander, worse than even my Steam Decks (which have sort of weird D-pads themselves)... you get the point. It's annoying that the device on which I would prefer to play 8 & 16 bit games at a 1:1/8:7 resolution has—out of everything I own—by far the worst controller for exactly those games.
The ergonomics also leave a bit to be desired. Again, like the D-pad, it's not so uncomfortable as to be unusable, though I much prefer pairing it with a 3D printed grip I bought from ComfortGrips on Etsy¹. That obviously makes it a much less pocketable device, which isn't a big deal for me, but might be for others.
Finally, I hesitate to critique the software experience, because on the whole I'm incredibly impressed with how much improvement I've seen (both in terms of quality and frequency of updates) to JELOS in the nearly five months I've owned the RGB30. But the fact remains that that confusing preference conflicts, occasional crashes, frequent sleep/wake flakiness, ridiculously bad battery drain when asleep or even fully powered off (which thankfully has been cleaned up in recent updates)... they're all just facts of life with the RGB30. It was honestly kind of shocking coming from OnionOS on the Miyoo Mini which is absolutely rock solid in comparison. But that's obviously a less powerful device with a completely different form factor.
Anyway, as lagniappe correctly pointed out, PowKiddy makes budget devices, which means they're generally inexpensive enough to take a flyer on despite their limitations, and the RGB30 is arguably the best thing they've ever made.
1. <https://www.etsy.com/listing/1602072205/powkiddy-rgb30-comfo...>
[+] [-] madduci|2 years ago|reply
[+] [-] renewiltord|2 years ago|reply
[+] [-] asimovfan|2 years ago|reply
[+] [-] freedomben|2 years ago|reply
For those not familiar with PICO-8:
> PICO-8 is a virtual machine and game engine created by Lexaloffle Games. It is a fantasy video game console[1] that mimics the limited graphical and sound capabilities of 8-bit systems of the 1980s to encourage creativity and ingenuity in producing games without being overwhelmed with the many possibilities of modern tools and machines."[1]
[1] https://en.wikipedia.org/wiki/PICO-8
[+] [-] cubano|2 years ago|reply
I have been looking for some sort of project to help pass the days and scratch my just build something dummy!-itch that had developed now that no one will hire me and I can work on anything that floats my boat.
This looks just perfect as far as 1] how cool the final output is 2] how complex the code is and 3] potential access to the original dev (well, we will see won't we? lol).
I already have a couple of ideas for some PICO-8 level games so I'm really excited about getting started...thank you very much for posting this!
[+] [-] joemi|2 years ago|reply
[+] [-] amethyst|2 years ago|reply
[+] [-] AugusteLef|2 years ago|reply
[+] [-] frenchie14|2 years ago|reply
[+] [-] freedomben|2 years ago|reply
[+] [-] vunderba|2 years ago|reply
https://github.com/kitao/pyxel
[+] [-] jamesgeck0|2 years ago|reply
TIC-80 is probably the closest open source thing to PICO-8. The browser builds ran 10% slower than the desktop app last I tried. It doesn't have a "CPU budget," so it's possible to write inefficient code that works fine on powerful machines but not slower ones.
[+] [-] WithinReason|2 years ago|reply
[+] [-] hombre_fatal|2 years ago|reply
As for the game, it's satisfying to ratchet down to the 39 second threshold for the gold medal by figuring our drifting. I realize I was overdrifting and easily beat 39 seconds once I stopped drifting much sooner along the turn.
[+] [-] frenchie14|2 years ago|reply
Does that one work better with vimium?
[+] [-] silenced_trope|2 years ago|reply
I usually just hit the "i" button to enter insert mode.
[+] [-] vincston|2 years ago|reply
[+] [-] vunderba|2 years ago|reply
[+] [-] VyseofArcadia|2 years ago|reply
[+] [-] bemmu|2 years ago|reply
I’ve been prototyping an f-zero type game and so far have:
- pressing forward increases thrust
- thrust makes vehicle accelerate forward
- friction is higher for the component of velocity perpendicular to tires
- vehicle turns faster when it is moving faster (I don’t actually simulate tire direction)
- as a hack to make it feel a bit like drifting, make the vehicle visually turn more than it is actually turning
Any simple thing I should add?
[+] [-] frenchie14|2 years ago|reply
- Wheel modifiers (which wheels are on road, grass, boost tiles, etc)
- Control loss when airborne
- Slow turning when at low speed (a bit different from yours since the impact drops to zero very quickly)
- Speed / accel penalty when hitting a wall
- Visually rotating the car (this is what happens when a player presses the turn key but the actual velocity rotation is handled separately)
- Boost handling
- Nudge the car to the side a little if it's trying to turn but is blocked by a wall
- Acceleration, friction, breaking, and drift-breaking
- Corrective side force (basically an extra friction perpendicular to velocity like you have)
- Artificial speed limit (alternatively, you can include a drag component which applies a force proportional to the square of speed, but I've found it hard to get this feeling good in the past)
- Velocity rotation to align velocity direction and visual direction. This is a minor effect - it's mostly handled by the other physics
- Gravity
- Out of bounds checks
I think you've got the main pieces already. What's more important is understanding what you want your game to feel like and continuously tweaking until you get there
[1] https://github.com/maxbize/PICO-8/blob/master/Driftmania/dri...
[+] [-] lbotos|2 years ago|reply
Do others expect the car be lined up to go right?
Is this a cultural expectation? I come from a LtR writing culture so I was wondering if others were surprised at the car going left at the start.
[+] [-] frenchie14|2 years ago|reply
[+] [-] grugagag|2 years ago|reply
Will definitely check this out..
[+] [-] gausswho|2 years ago|reply
[+] [-] Moru|2 years ago|reply
[+] [-] VyseofArcadia|2 years ago|reply
[+] [-] frenchie14|2 years ago|reply
[+] [-] japhib|2 years ago|reply
[+] [-] sen|2 years ago|reply
I find it way easier/faster than using the built-in IDE for the code part itself. Then just use the built-in IDE for assets/music.
[+] [-] hombre_fatal|2 years ago|reply
[+] [-] AlienRobot|2 years ago|reply
[+] [-] d--b|2 years ago|reply
[+] [-] wkirby|2 years ago|reply
[+] [-] unknown|2 years ago|reply
[deleted]
[+] [-] ambigious7777|2 years ago|reply
[+] [-] frenchie14|2 years ago|reply
[+] [-] willio58|2 years ago|reply
[+] [-] theogravity|2 years ago|reply
[+] [-] bowsamic|2 years ago|reply