sync rate 60
sync on
load object "player.x",1
load image "base1.jpg",1
make matrix 1,1000,1000,500,500
prepare matrix texture 1,1,5,5
texture object 1,1
px = object position x(1)
py = object position y(1)
pz = object position z(1)
do
position camera 0,px,py+550,pz
point camera 0,px,0,pz
mx#=mousemovex()/2.0
my#=mousemovey()/2.0
cam#=wrapvalue(cam#+mx#)
rotate object 1,0,cam#,0
if keystate (17) = 1
move object 1,1
endif
sync
loop
Per loop only read once the mousemovex() and mousemovey().
Also your object needs its pivot fixing so it points the correct way. When you press "W" I've got it now so it should move forward but your object is at the wrong angle.
Warning! May contain Nuts!