Quote: " Directional Light"
i believe that was replaced with the Sun:
// Project: Sun
// Created: 2022-01-03
// By: Virtual Nomad
// show all errors
SetErrorMode(2)
// set window properties
SetWindowTitle( "Sun" )
SetWindowSize( 1280,720, 0 )
SetWindowAllowResize( 1 )
// set display properties
SetVirtualResolution( 1280,720)
SetOrientationAllowed( 1, 1, 1, 1 )
SetSyncRate( 30, 0 )
SetScissor( 0,0,0,0 )
UseNewDefaultFonts( 1 )
ground = CreateObjectPlane(200,200) : RotateObjectLocalX(ground,90) : SetObjectReceiveShadow(ground,1)
for x = 1 to 75
y = random(5,50)
this = CreateObjectBox(10,y,10) : SetObjectPosition(this,random(0,180)-90,y/2.0,random(0,180)-90)
SetObjectCastShadow(this,1) : SetObjectColor(this,random(128,255),random(128,255),random(128,255),255)
next x
SetCameraPosition(1,0,100,-150) : SetCameraLookAt(1,0,0,0,0)
SMode = 3
SetShadowMappingMode(SMode) : SetShadowSmoothing(0)
SetShadowMapSize( 1024, 1024 )
do
If GetRawKeyState(27) then Exit
INC Angle
if Angle = 360
Angle = 0
INC SMode : if SMode = 4 then SMode = 0
SetShadowMappingMode(SMode)
EndIf
x# = SIN(Angle)
z# = COS(Angle)
SetSunDirection(x#,-1,z#)
Print( Angle )
Print( SMode )
Sync()
loop