Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Use p 5 . js or VS code to make Super sprint game The program should read a track in from a file called track
Use pjs or VS code to make Super sprint game
The program should read a track in from a file called tracktxt should indicate grass, should indicate track and should indicate startfinish line. You should finddraw appropriate images to use as tiles to represent these components, and it is recommended that you load them in as sprites. Each tile should have dimensions controlled by variables, and be positioned according to the input file. If the input file is x numbers, you should draw this many tiles. The track is static, so this could be drawn in the setup phase, but you will need access to this data for detecting the car leaving the track
The program should draw a car as a sprite on the start finish line, facing one of the adjacent road tiles. You could draw or find a suitable image to use. The car size should be controlled by a variable but always smaller than the tile size and be placed in the middle of the road.
The program should allow for inputs updown and leftright on the keyboard. Up and down should modify the velocity of the car you should impose limits so it cannot go too fast or backwards Left and right should rotate the angle it is facing and moving. This should be done in a smooth way so the car cannot execute instant degree turns
If the car leaves the track and hits the grass, the game should reset to the start position simply move the car back to its initial position i need complete solution just do it push it in the github and provide me the repo of github so everrything should be provided. just i need to cloned it and run it do it hep me guys
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started