code
Sync on : Sync rate 35
all()
function all()
load()
makeobjects()
setcamerapos()
mainloop()
endfunction
function mainloop()
do
moveobjects()
editobjects()
sync
loop
endfunction
function makeobjects()
make object sphere 1,1
show object 1
endfunction
function editobjects()
rem had a texture for the object here but i wasn't going to put the file online
endfunction
function moveobjects()
if upkey() = 1
position object 1, object position x (1), object position y (1), object position z (1)+.01746
xrotate object 1, object angle x (1)+2
position camera camera position x (0) , camera position y (0), camera position z (0)+.01746
endif
if downkey() = 1
position object 1, object position x (1), object position y (1), object position z (1)-.01746
xrotate object 1, object angle x (1)-2
position camera camera position x (0) , camera position y (0), camera position z (0)-.01746
endif
if leftkey() = 1
position object 1, object position x (1)+.01746, object position y (1), object position z (1)
zrotate object 1, object angle z (1)+2
position camera camera position x (0)+.01746 , camera position y (0), camera position z (0)
endif
if rightkey() = 1
position object 1, object position x (1)-.01746, object position y (1), object position z (1)
zrotate object 1, object angle z (1)-2
position camera camera position x (0)-.01746 , camera position y (0), camera position z (0)
endif
endfunction
function load()
rem used to be texture here but i wasn't going to bother putting that online for you to test
endfunction
function setcamerapos()
position camera camera position x(0)+1, camera position y(0)+2, camera position z(0)-2
point camera object position x (1), object position y (1), object position z (1)
endfunction
/code
thats what i have, i think the camera is following it, but i dont have a textured ground to see if it is actually moving or not, but im having a problem with it, the sphere will roll forward and backwards fine (note, the camera angle is off at a 3rd person type of angle) but when i go left and right, it messes up the position of the x axis, if you cant piccture what im saying, take that code and run it in dbpro... i took out the texture so u need to texture it yourself to see if it is moving easier or not... thanks
Welcome to Hypocrite In A Box, May I change your order?