Supercars JSE

Started by Pakz, June 02, 2022, 06:58:12

Previous topic - Next topic

Pakz

I noticed Qube made a really nice looking racing game. I myself was doing a attempt at a 2d Supercars remake after figuring out how to do a bot on a racetrack.

Yesterday I spent a long time trying to tweak code to have a whole group of ai racers be able to drive a track. I'm coding it in jayenkai's browser language. (Gotojse.com)
I have a part of the Supercars Amiga's tile set and sprites redone in the built in sprite editor.
Various stages of the project are on my github.

https://github.com/Pakz001/jseexamples

Inside the games/supercars folder. Just paste the code into a new project on www.gotojse.com There is no human player yet. (Figuring out a control system for touchscreen!) I'm coding it on a ipad.

I'm hoping to create a random map generator that creates race tracks that look a bit like the ones in Supercars. Last night I think I have figured out a way to lay out a track and tile this. I'm hoping the line track system wil be able to be used on top of the tiled maps.
The bot racing system as it is now works that bots follow a point on a connected series of lines. This point has a distance from the center outwards to either side to the edges. It gets pushed ahead when the bot gets closer. The book 'nature of code' is a great help for this!

The code is open. Use and tweak as you will. It is a bit messy.

edit: I just tested on a older laptop. The framerate is real bad. I think I wil need to work this out too. On my ipad it runs very fast.