The UV offset didn't behave how I expected.
I found help on the forum to make this...
// Project: UV offset
// Created: 23-12-18
SetErrorMode(2)
width# = GetMaxDeviceWidth()
height# = GetMaxDeviceHeight()
SetWindowSize(width#,height#,1)
SetVirtualResolution(width#,height#)
SetVSync(1)
SetScissor(0,0,0,0)
UseNewDefaultFonts(1)
SetSunActive(0)
SetAmbientColor(120,120,120)
light1=1
CreatePointLight(light1,0,0,80000,100000,255,255,255)
SetPointLightMode(light1,1)
// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx flaming star animation - 256 frame atlas (16x16)
startex=loadimage("explosion51.png")
starplane=createobjectplane(50000,50000)
SetObjectImage(starplane,startex,0)
SetObjectposition(starplane,0,0,100000)
startex2=CreateImageColor(200,200,0,255)
SetObjectImage(starplane,startex2,1)
SetObjectColor(starplane,190,190,255,255)
SetObjectTransparency(starplane,1)
SetObjectUVScale(starplane,0,0.0625,0.0625)
SetObjectColorEmissive(starplane,0,255,255)
cam1=1
SetCameraRange(cam1, 0.1, 5000000 )
SetCameraRotation(cam1,0,0,0)
do
// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx flaming star animation
starclock=starclock+1
if starclock>1
starclock=0
u=u+1
if u=16
u=0
v=v+1
if v=16 then v=0
endif
SetObjectUVOffset(starplane,0,u*0.0625,v*0.0625)
endif
Sync()
if GetrawKeyPressed(27) then end
loop
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.