Rem ***** Main Source File *****
Sync On
Autocam Off
REM SKY OBJECT
Load Object "sky/sky.x", 10
objectScale(10, 500)
Set Object Light 10, 0
Set Object Fog 10, 0
Set Object Texture 10, 2, 0
Position Object 10, 0, 0, 0
REM WATER
Load Image "water/waves.bmp", 1
Load Image "water/waves.dds", 2
Load Image "water/refract.bmp", 3
Load Object "plain.x", 1, 2
objectScale(1, 500)
xRotate Object 1, 90
Position Object 1, 0, 0, 0
Set Object Diffuse 1, Rgb(128,128,128)
Set Object Emissive 1, Rgb(128,128,128)
Set Object Specular 1, Rgb(128,128,128)
Set Object Ambience 1, Rgb(128,128,128)
Set Blend Mapping On 1, 1, 2, 3, 24
Set Blend Mapping On 1, 2, 1, 3, 4
Set Blend Mapping On 1, 3, 3, 3, 26
Set Blend Mapping On 1, 4, 2, 11, 24
Set Blend Mapping On 1, 5, 1, 11, 7
Scale Object Texture 1, 0, 5, 5
Scale Object Texture 1, 1, 50, 50
Ghost Object On 1, 2
Position Camera 0, 1, 0
Do
ax# = WrapValue(ax# + mousemovey())
ay# = WrapValue(ay# + mousemovex())
Rotate Camera ax#, ay#, 0.0
If MouseClick()=1 Then Move Camera 1
If MouseClick()=2 Then Move Camera -1
REM MAKE CLOCKWISE ANGULAR WAKES(optionally just make them straıght for a better look)
ang# = WrapValue(ang# + 0.1)
Scroll Object Texture 1, 0, -Sin(ang#)*0.0001, Cos(ang#)*0.0001
Scroll Object Texture 1, 1, 0.0001, 0.0
Sync
Loop
End
Function objectScale(obj as Integer, Size As Float)
scale# = Size / Object Size X(obj) * 100
Scale Object obj, scale#, scale#, scale#
EndFunction