; Quickly set up a scene Graphics3D 800,600 SetBuffer BackBuffer() WireFrame True Global cube = CreateCube() Global cam = CreateCamera() TranslateEntity cam, -5, -2, -5 PointEntity cam, cube CameraViewport cam, 0, 0, GraphicsWidth (), GraphicsHeight () ; We're going to rotate a cube between these two angles: (sp = start pitch, er = end roll, etc) Global sp# = 90, sy# = 0, sr# = 0 ; The start rotation Global ep# = 0, ey# =-90, er# = 90 ; The end rotation ; Start off by rotating the cube to it's initial rotation RotateEntity cube, sp, sy, sr, 1 CaptureWorld : RenderWorld Text 10, 10, "Press escape for ideal rotation" : Flip 1 : Repeat : Until KeyHit(1) ; Show the rotation we want to achieve, by using Blitz's tweening RotateEntity cube, ep, ey, er, 1 For t = 0 To 200 RenderWorld Float(t)/200 Flip 1 Next Text 10, 10, "Press escape for our own rotation" : Flip 1 : Repeat : Until KeyHit(1) ; Try to emulate the rotation For t = 0 To 200 RotateCube(Float(t)/200) CaptureWorld : RenderWorld Flip 1 Next Text 10, 10, "Press escape to end" : Flip 1 : Repeat : Until KeyHit(1) End Function RotateCube(tween#) ; Delete this code, replace it with something that works! RotateEntity cube, (ep - sp)/tween, (ey - sy)/tween, (er - sr)/tween, 1 End Function