loook at this code
randomize timer()
sync on
sync rate 60
make camera 2
set camera view 0,0,0,320,480
set camera view 2,320,0,640,480
color backdrop RGB(0,0,255)
make object triangle 20,-0.5,-0.5,0,0.5,-0.5,0,0,1,0
set object collision to polygons 20
set ambient light 100
shld = 3
set object wireframe 20,1
rem color object 20,RGB(0,255,0)
for t = 1 to 19
make object cube t,0.1
rem color object t,RGB(255,0,0)
next t
for t=21 to 60
make object cylinder t,0.7
rem color object t,RGB(128,64,0)
set object wireframe t,1
next t
dim aster(40)
dim blttime(19)
nas = 4
for t = 1 to nas
aster(t) = 3
yrotate object (t+20),rnd(360)
move object (t+20),rnd(13)+7
next t
position camera 0,0,30,0
xrotate camera 0,90
xrotate object 20,90
position camera 2,0,30,0
xrotate camera 2,90
do
ang# = ang# - (leftkey()-rightkey()) * 4
yrotate object 20,ang#
if upkey() = 1
xs# = xs# + (sin(ang#)/300)
zs# = zs# + (cos(ang#)/300)
endif
x# = x# + xs#
z# = z# + zs#
position object 20,x#,0,z#
if z# > 19 then z# = -19
if z# 25 then x# = -25
if x# 20
if object position z(t) > 19
position object t,object position x(t),0,-19
endif
if object position z(t) 25
position object t,-25,0,object position z(t)
endif
if object position x(t) 0.3 then xs# = 0.3
if zs# > 0.3 then zs# = 0.3
if xs# 0
move object t,0.3
blttime(t) = blttime(t) - 1
endif
if blttime(t) = 0
hide object t
endif
next t
for t = 1 to 40
if aster(t) > 0
show object t+20
move object t+20,0.2
if sqrt((object position x(t+20)-x#)^2+(object position z(t+20) - z#)^2) 0 and blttime(t) > 0
if sqrt((object position x(t)-object position x(n+20))^2+(object position z(t) - object position z(n+20))^2)
Life is a terminal disease.
You never survive it.