View Single Post
try this
Old
rich0e0rick
Senior Member
 
rich0e0rick's Avatar
 
Status: Offline
Posts: 141
Join Date: Jan 2008
Location: Sturgeon Falls
Talking try this - 09-15-2008, 05:59 PM

i recently added this on my game so i will explain it to you...

first, add 3 variables either in the world properties or on the plane properties, top speed, slow speed, and plane speed...

next make a method in a infinite loop (plane move forward at (plane speed))

next add 2 WHEN A KEY IS TYPED events and change those to WHILE KEY IS PRESSED

for the first event, put in the key u want to use to accelerate, and put in the DURING this

IF (plane plane speed is less than top speed)
increment (plane speed) by 1 , at duration (acceleration speed)(i put 0.25)


for the second event put the key you want to use to slow down and put in the DURING:

IF (plane plane speed is bigger than slow speed)
decrement (plane speed) by 1 , at duration (acceleration speed)(i put 0.25 again)

and that should work!

rick


im back!!! FINNALY!!! got windows working on my mac again!!!
   
Reply With Quote