Skip to content

the-baaron/racer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CIRCUIT RACER

Hi, Thanks for checking out this experimental Racing game. The past few weeks I've been working on making it as best as I could in the time I had, I'll continue working on it when I've got more free time.

NOTE: After you select a track, you have to resize the browser for it to show (I can't find the solution for this bug...)

What it does

It's a simple racing game with the posibility to add or change tracks in a very simple way (just take a look at one of the track files). You can drive around with the arrow keys.

What the files do

For a detailed description, please click the links:

Link What the file manages
main.js The canvas element and init the game functions
preloader.js The preloader
draw.js The draw functions for each object
track.js The tiles that are needed for the track
car.js The speed and direction of the car
camera.js The position of the 'camera'
controls.js The pressed keys to control the car
ui.js Draws the buttons and other elements of the UI
helpers.js Helper functions such as a clickhandler
settings.js The game settings (not much)

To do

  • Make the finish count laps
    • Add checkpoints to prevent cheating
  • Add grass where there is no map
  • Add objects to collide in
  • Add tire tracks when the car is braking or drifting
  • Add W, S, A and D as 2nd controls to drive the car
  • The router shouldn't be in draw.js, should be merged with router.js
  • Add a favicon
  • change settings.js into a json file
  • Design and implement the menu
  • Add Collision detection
    • Drive slow on grass
    • Crash into solid objects ➞ there arn't any yet
  • In preloader.js, a function is declared in a for-loop

Known bugs

I've been working hard to get it where it is now, unfortunately there still are some bugs.

  • You have to resize the browser when you choose a track ➞ it doesn't automatically redraw

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published