yeah i know i looked at it.and after 30 minutes i understood a few lines
but now i understand the whole code and it was 123 lines.But my code is something about 240.
this is the original code :
` This code was downloaded from The Game Creators
` It is reproduced here with full permission
` http://www.thegamecreators.com
REM -- REVS Test
Set display mode 1024, 768, 32
sync on : sync rate 30
rem -- CREATE TERRAIN
make matrix 1,5000,5000,50,50
rem -- CREATE PLAYER
make object box 10,40,20,60
set object wireframe 10,1
rem -- TILT Object
make object cone 1,5
glue object to limb 10,1,0
spd# = 0 : rem -- Global speed value
spd_max# = 24 : rem -- Max speed, 240 km/h
spd_acc# = 0.1 : rem -- acceleration
bank# = 0 : rem -- Car bank value
bank_max# = 3 : rem -- Max value the car turns
bank_inc# = 3 : rem -- SUSPENSION - 1 HARD - 10 LOSE
skida# = 0 : rem -- DRIFTING
do
rem -- CAMERA
set camera to follow x#,y#,z#,a#,90,90,10,0
point camera x#,y#,z#
rem -- SPEED UP
if upkey() = 1
if spd# < spd_max#
inc spd#,spd_acc#
endif
endif
rem -- SPEED DOWN
if upkey() = 0
if spd# > 0
dec spd#,(spd_acc#/2)
endif
if spd# < 0
spd# = 0
endif
endif
rem -- BRAKE
if downkey() = 1
if spd# > 0
dec spd#,(spd_acc#*2)
endif
if spd# < 0
spd# = 0
endif
skid = 1
endif
rem -- TURN LEFT
if leftkey() = 1
if bank# > (0-bank_max#)
bank# = curvevalue((0-bank_max#),bank#,10)
endif
if upkey() = 0
skid = 1
else
skid = 0
endif
endif
rem -- TURN RIGHT
if rightkey() = 1
if bank# < bank_max#
bank# = curvevalue(bank_max#,bank#,20)
endif
if upkey() = 0
skid = 1
else
skid = 0
endif
endif
rem -- BRING CAR BODY BACK IN POSITION
if leftkey() = 0 AND rightkey() = 0
bank# = curvevalue(0,bank#,10)
skida# = curvevalue(0,skida#,10)
endif
rem -- SKID CAR
if skid = 1
if leftkey() = 1 then skida# = curvevalue(0-(spd#*2),skida#,30)
if rightkey() = 1 then skida# = curvevalue((spd#*2),skida#,30)
dec spd#,(spd_acc#/2)
print "SKIDDING!!!"
else
skida# = curvevalue(0,skida#,10)
endif
rem -- UPDATE VALUES
x#=newxvalue(x#,a#,spd#) : z#=newzvalue(z#,a#,spd#)
a# = wrapvalue(a#+bank#)
rem -- UPDATE CAR POSITION AND ANGLES
position object 1,x#,y#,z#
yrotate object 1,a#
zrotate object 10,(bank#*bank_inc#*(spd#/20))
yrotate object 10,skida#
rem -- PRINT SOME THINGIES
set cursor 0,0
print "Speed: "+str$(spd#*10)+" Km/h"
print "Banking: "+str$(bank#)
sync
loop