movement.bb 534 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. ; Movement & Rotation ***
  2. ; By Paul Gerfen (www.gamecoding.co.uk)
  3. Graphics3D 800,600
  4. SetBuffer BackBuffer()
  5. camera=CreateCamera()
  6. CameraViewport camera,0,0,800,600
  7. light=CreateLight()
  8. rocket=LoadMesh( "rocket.3ds" )
  9. PositionEntity rocket,0,0,7
  10. While Not KeyHit(1)
  11. If KeyDown(200) Then
  12. MoveEntity rocket,0,0.05,0
  13. EndIf
  14. If KeyDown(203) Then
  15. TurnEntity rocket,0,0,1.0
  16. EndIf
  17. If KeyDown(205) Then
  18. TurnEntity rocket,0,0,-1.0
  19. EndIf
  20. UpdateWorld
  21. RenderWorld
  22. Text 320,500,"Movement & Rotation"
  23. Flip
  24. Wend
  25. End