This is a start to a 3-d side scrolling game. I put in a gravity system and a jumping system. I hope someone will find it useful.
`screen settings
sync on
sync rate 40
hide mouse
`make a player pawn
make object sphere 1,5
color object 1,rgb(0,255,255)
set object collision to spheres 1
yrotate object 1,wrapvalue(object angle y(1)+90)
`make the main platform
make object box 2,1000,5,7
position object 2,object position x(2)+500,object position y(2)-50,object position z(2)
set object collision to boxes 2
set object collision on 2
`make lower platforms
for x=3 to 53
make object box x,7,3,3
position object x,rnd(1000),object position y(2)+20,object position z(2)
color object x,rgb(rnd(155)+100,rnd(155)+100,rnd(155)+100)
next x
`make higher platforms
for x=3 to 53
make object box x+101,7,3,3
position object x+101,rnd(1000),object position y(2)+40,object position z(2)
color object x+101,rgb(rnd(155)+100,rnd(155)+100,rnd(155)+100)
next x
jumptime=0
`main loop
do
x#=object position x(1)
`determine if object is in the air
if air=1 then position object 1,object position x(1),object position y(1)-1,object position z(1)
if object collision(1,0)>0 then air=0
if object collision(1,0)=0 then air=1
`determine if it is jumping
if jump=1 and jumptime<25
inc jumptime
air=0
position object 1,object position x(1),object position y(1)+1,object position z(1)
if object position y(1)=>object position y(2)+25 and jumptime=25
jumptime=0
jump=0
air=1
endif
endif
`accept keyboard input
if leftkey()=1 then move object 1,-1
if rightkey()=1 then move object 1,1
if spacekey()=1 and jump=0 and air=0 then jump=1
`set the position of the camera
position camera x#,object position y(1)+10,object position z(1)-120
`refresh the screen
sync
`end the main loop
loop
Seriously, are sigs even worth it?