SETCURRENTDIR("Media") /// NOTE bump.png is in the MEDIA directory
TestJim()
FUNCTION TestJim:
camera=EntityCreateCamera()
EntityEnable(camera, TRUE)
EntitySetCameraRange(camera,1,4000)
light = EntityCreateLight(RGB(255,255,255) )
cube = EntityCreateCube(1)
EntitySetPosition(camera,0,0,-10)
EntityParent(light, camera)
jtex = EntityLoadTexture("bump.png")
notex=EntityMakeNullTexture()
EntityApplyTexture(cube,jtex,notex)
//EntitySetAlpha(cube,0.5)
WHILE TRUE
// Draw all entites, using entity camera
IF (KEY(200))
EntityMove(camera,0,0,0.2)
ENDIF
IF (KEY(208))
EntityMove(camera,0,0,-0.2)
ENDIF
IF (KEY(203))
EntityRotate(camera,0,1,0)
ENDIF
IF (KEY(205))
EntityRotate(camera,0,-1,0)
ENDIF
EntityRotate(cube,1,0,0)
EntityDrawSystem()
SHOWSCREEN
WEND
ENDFUNCTION