I was having some fun and managed to get this kinda of working. It doesn't really have physics or anything special, but I had fun!
Code:
set display mode desktop width(), desktop height(), 32
sync on
sync rate 60
autocam off
color backdrop 0
fog on
fog distance 20,2000
set camera range 10,2000
for a = 1 to 100
for b = 1 to 100
dot a,b,rgb(rnd(50),rnd(150)+50, rnd(50))
next b
next a
get image 1,1,1,100,100
make matrix 1, 50000,50000,100,100
randomize matrix 1, 100
prepare matrix texture 1,1,1,1
set matrix texture 1,1,1
position matrix 1,-25000,0,-25000
update matrix 1
position camera 0,120,200
point camera 0,0,0
make object box 1, 10,10,50
position object 1,0,120,0
make object box 2, 30,1,5
position object 2, 0,0,25
make object box 3,50,1,10
position object 3, 0,0,-10
glue object to limb 2,1,0
glue object to limb 3,1,0
global Speed# = 2.0
global GrndHeight#
global Altitude#
do
AirControls()
Camera()
DataCatch()
OnScreenText()
Crash()
sync
loop
end
function AirControls()
if keystate(32) = 1 then roll object left 1,1
if keystate(30) = 1 then roll object left 1,-1
if keystate(17) = 1 then pitch object up 1,1
if keystate(31) = 1 then pitch object up 1,-1
If keystate(38) = 1 then inc Speed#, .1
If keystate(37) = 1 then dec Speed#, .1
If Speed# < 0.0 then Speed# = 0.0
If Speed# > 5.0 then Speed# = 5.0
If Speed# < 2.0 then position object 1, object position x(1), (object position y(1))-(2.0-Speed#), object position z(1)
move object 1, Speed# *-1.0
endfunction
function camera()
position camera object position x(1), object position y(1), object position z(1)
rotate camera object angle x(1),object angle y(1), object angle z(1)
move camera 200
point camera object position x(1), object position y(1), object position z(1)
rotate camera camera angle x()-90, camera angle y(), camera angle z()
move camera 20
point camera object position x(1), object position y(1), object position z(1)
endfunction
function DataCatch()
GrndHeight# = get ground height(1, object position x(1)+25000, object position z(1)+25000)
Altitude# = Object position y(1) - GrndHeight#
endfunction
function OnScreenText()
set cursor 0,0
print "A to roll left"
print "D to roll right"
print "W to pitch forward"
print "S to pull back"
print
print "L to increase speed"
print "K to decrease speed"
set cursor 0,desktop height()-50
print "Speed: ", speed#*100, " mph"
set cursor 200,desktop height()-50
print "Altitude: ", (Altitude#)-5, " ft"
endfunction
function crash()
if Altitude# < 0
center text desktop width()/2, desktop height()/2, "YOU CRASHED!!!! Press any key to exit."
sync
wait key
end
endif
endfunction
It might give some ideas that you can develop upon.
There's something in this room that makes you can't speak well.