not sure if this would help, i don't understand maths to well but this is a 3rd person camera demo type thing:
sync on
hide mouse
rem make and place cubes randomly
for c=1 to 25
make object cube c,50
position object c,rnd(2000),0,rnd(2000)
next c
rem makes a sphere
make object sphere 30,50
do
rem stores the y angle of object 1
ay#=object angle y(10)
rem controls
if upkey()=1
move object 10,5
endif
if downkey()=1
move object 10,-5
endif
if rightkey()=1
yrotate object 10,wrapvalue(ay#+5)
endif
if leftkey()=1
yrotate object 10,wrapvalue(ay#-5)
endif
rem get player position and store in x# and z#
x#=object position x(10)
z#=object position z(10)
rem get new camera position and store in cz# and cx#
rem change the last parameter to move the camera further from the player
cz#=newzvalue(z#,ay#-180,200)
cx#=newxvalue(x#,ay#-180,200)
rem position the camera (x,y,z)
position camera cx#,100,cz#
rem point camera at player
point camera x#,50,z#
sync
loop
#for dbc
dunno if it'll be any use
hi guys