Hello , I have a problem with the "position camera" function , hope you can help me . I have a function called move_camera()
function move_camera()
`move left right forward and backwords with keys
if leftkey()=1
position camera o_camera,camera position x()-5,camera position y(),camera position z()
endif
if rightkey()=1
position camera o_camera,camera position x()+5,camera position y(),camera position z()
endif
if upkey()=1
position camera o_camera,camera position x(),camera position y(),camera position z()-5
endif
if downkey()=1
position camera o_camera,camera position x(),camera position y(),camera position z()+5
endif
`move up and down with the terrain
position camera o_camera,camera position x(),get terrain height(t_terrain,camera position x(),camera position z())+60,camera position z()
endfunction
I load a terrain (heightmap) and then in the main loop I have :
do
move_camera()
sync
loop
The problem is that the camera dosen't move . Why is that ????
If I use control camera using arrowkeys 0,1,1 it works , but I don't want to use this command becouse I want my camera to strafe , not rotate . Hope you can help me .
I am a Sodevrom team member .
Visit www.sodevrom.com for free games & software
And don't forget : We make what you only imagine