Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Car racing game #120

Open
Surajvatsya opened this issue Jul 28, 2021 · 5 comments
Open

Car racing game #120

Surajvatsya opened this issue Jul 28, 2021 · 5 comments

Comments

@Surajvatsya
Copy link

Proposal

I'm designing a js car racing game. In this game, player is in a race track protecting himself from collision from other cars
coming on the way.

This game is purely coded on javascript language and a little bit of CSS is used for styling backgrounds and all.
First of all, I have designed a div by name “carGAme”, after that a new div of “gameArea” I made, followed by “startScreen” div where you got instruction of how to play this game and finally a div for displaying the score.
 I have fired an event on arrow keys, arrowDown for getting back on road, arrowup for move ahead ,arrowleft & arrowRight for left & right direction respectively. When we started game I put player.score value=0, now I have designed 5 road line & through a call back function we have repeated it in gameArea. After this I put 3 enemy car on road and repeat it until collision take place. Now defined the speed of player as 5px and increases player score until he quit/collide. When collision take place startScreen again come on top of screen showing final score and instruct user to play again

Hit this link to play game:-
https://car-racing-app-surajvatsya.herokuapp.com/

image

@github-actions github-actions bot added the DCP21 label Jul 28, 2021
@github-actions
Copy link

Hello there!👋 Welcome to the project!🚀⚡ Thank you and congrats🎉 for opening your very first issue in this project. Please adhere to our Code of Conduct. Please make sure not to start working on the issue, unless you get assigned to it.😄

@Surajvatsya
Copy link
Author

@geekymeeky please assign it to me, it has been more than 4 days.

@geekymeeky
Copy link
Owner

@Surajvatsya we already have a car game that is quite similar to this one. You can modify the existing game to add features. Let me know if you need suggestion

@Surajvatsya
Copy link
Author

@geekymeeky please suggest to me, what can I do to enhance that game.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants
@geekymeeky @Surajvatsya @madihamallick and others