i have this code:
Code: Select all
If InitEngine3D()
InitSprite()
InitKeyboard()
; get screen size
ExamineDesktops()
DesktopW = DesktopWidth(0)-10
DesktopH = DesktopHeight(0)-60
OpenWindow(0, 0, 0, DesktopW, DesktopH, "Rotating cube")
OpenWindowedScreen(WindowID(0), 0, 0, DesktopW, DesktopH, 0, 0, 0)
; cube creation
CreateCube(1,35)
CreateEntity(1, MeshID(1), #PB_Material_None)
;-Camera
CreateCamera(0, 0, 0, 100, 100)
MoveCamera(0, 0, 0, 150, #PB_Absolute)
CameraBackColor(0, RGB(0, 0, 40))
;-Light
CreateLight(0, RGB(255,255,255), -10, 60, 10)
AmbientColor(RGB(90, 90, 90))
; game loop
Repeat
Event = WindowEvent()
ExamineKeyboard()
; rotate cube
RotateEntity(1, 0.5, 0.5, 0.5, #PB_Relative)
RenderWorld()
FlipBuffers()
Until KeyboardPushed(#PB_Key_Escape) Or Quit = 1
EndIf
End
what do i miss here?

