PDA

View Full Version : help neaded with drag racing game


ZW3039
12-14-2010, 03:51 PM
ok im making a drag racing game for my final project and i cant seem to figure out how to make the world stop after the first car gets to the finish line also i want as it stops to show the race times but that is also somthing i am having trouble figuring out. if some one knows how to help me or can do it for me wright back i need help my other problem is im trying to make my red light go off if i go before the green lite to end game and that is not working eather. i tired to just cancle the the let arrow keys move convertable corvett until the light turns green but im am having no luck please help me

haven812
12-14-2010, 04:50 PM
We can't do your school work for you, but I suggest experimenting with boolean variables. For example, for the part where you want the cars to stop, make it so whenever the car moves, it checks the boolean to see if it should move or not. i.e
if canMove
car move forward 1m 0.25 seconds

you can loop this until the car reaches the finish. You can also do the same thing with a while loop.
while canMove
car move forward 1m 0.25 seconds

when either car reaches the finish, set canMove to false...

I hoped this helped!

Revolt
12-14-2010, 06:29 PM
:eek:
How did you do that? With the code in the scroll boxes, I mean.

haven812
12-14-2010, 07:07 PM
:eek:
How did you do that? With the code in the scroll boxes, I mean.

just highlight the text you want to be in code, then click the little code button at the top (#)

lsutigers
12-14-2010, 08:36 PM
that makes no sense because it does not know if something can move or not and you dont tell it what to move...

haven812
12-14-2010, 08:39 PM
I didn't do the entire project for you and I am sorry for that. You should try experimenting with booleans and implement them in the drag racing game. I assumed you already knew how to make objects move

Revolt
12-14-2010, 09:45 PM
I didn't do the entire project for you and I am sorry for that. You should try experimenting with booleans and implement them in the drag racing game. I assumed you already knew how to make objects move

If there was a clap emoticon, you would have earned it, my good sir! There are so many people asking for community to do their whole homework/projects to be done... :D