Why dont the movement keys work in this:
Graphics3D 640,480
SetBuffer BackBuffer()
light=CreateLight()
camera=CreateCamera()
RotateEntity camera,5,0,0
Floor1=CreatePlane()
PositionEntity Floor1,0,-2,0
FloorTex=LoadTexture("floor.bmp")
EntityTexture Floor1, FloorTex
leftwall=CreateCube()
PositionEntity leftwall,-5,0,0
While Not KeyHit(1)
a3DmovementKeys(0.4, camera)
RenderWorld
Flip
Wend
End
Function a3DmovementKeys(speed, camera)
;up arrow
If KeyDown(200) MoveEntity camera,0,0,speed
;down arrow
If KeyDown(208) MoveEntity camera,0,0,-speed
;Left arrow
If KeyDown(203) MoveEntity camera,-speed,0,0
;Right arrow
If KeyDown(205) MoveEntity camera,speed,0,0
End Function
|