Tell me, what's wrong with this?
I can't see the earth...
Graphics3D 640,480
SetBuffer BackBuffer()
light=CreateLight()
camera=CreateCamera()
PositionEntity camera, 0,0,-7
sun=CreateSphere (16)
PositionEntity nucleus, 0,0,1
tex=LoadTexture( "thesun.jpg" )
EntityTexture sun,tex
;glow setup
s=1
Global sizex=640/s
Global sizey=480/s
Global glowtexture=CreateTexture (384,384,256)
Global sp=CreateSprite(camera)
MoveEntity sp,-.25,-0.06,1.18
EntityAlpha sp,.32
ScaleTexture glowtexture,GraphicsWidth()/sizex,GraphicsHeight()/sizey
EntityTexture sp,glowtexture
TextureBlend glowtexture, 5
While Not KeyDown( 1 )
TurnEntity sun,0.5,0.5,0.5
RenderWorld
CopyRect 0,0,sizex,sizey,0,0,BackBuffer(),TextureBuffer(glowtexture)
CameraViewport camera,0,0,GraphicsWidth(),GraphicsHeight()
Wend
pivot=CreatePivot()
PositionEntity pivot,0,0,1
orbit=CreateSphere(16,pivot)
tex1=LoadTexture( "orbit.jpg" )
EntityTexture orbit, tex1
ScaleEntity orbit, 0.3,0.3,0.3
PositionEntity orbit,4,0,0
While Not KeyDown (1)
TurnEntity pivot,0,3,0
pitch#=pitch#+1 yaw#=yaw#+1 roll#=roll#+0
RotateEntity sun,pitch#,yaw#,roll#
RenderWorld
Flip
Wend
End
I can't see the earth...
Graphics3D 640,480
SetBuffer BackBuffer()
light=CreateLight()
camera=CreateCamera()
PositionEntity camera, 0,0,-7
sun=CreateSphere (16)
PositionEntity nucleus, 0,0,1
tex=LoadTexture( "thesun.jpg" )
EntityTexture sun,tex
;glow setup
s=1
Global sizex=640/s
Global sizey=480/s
Global glowtexture=CreateTexture (384,384,256)
Global sp=CreateSprite(camera)
MoveEntity sp,-.25,-0.06,1.18
EntityAlpha sp,.32
ScaleTexture glowtexture,GraphicsWidth()/sizex,GraphicsHeight()/sizey
EntityTexture sp,glowtexture
TextureBlend glowtexture, 5
While Not KeyDown( 1 )
TurnEntity sun,0.5,0.5,0.5
RenderWorld
CopyRect 0,0,sizex,sizey,0,0,BackBuffer(),TextureBuffer(glowtexture)
CameraViewport camera,0,0,GraphicsWidth(),GraphicsHeight()
Wend
pivot=CreatePivot()
PositionEntity pivot,0,0,1
orbit=CreateSphere(16,pivot)
tex1=LoadTexture( "orbit.jpg" )
EntityTexture orbit, tex1
ScaleEntity orbit, 0.3,0.3,0.3
PositionEntity orbit,4,0,0
While Not KeyDown (1)
TurnEntity pivot,0,3,0
pitch#=pitch#+1 yaw#=yaw#+1 roll#=roll#+0
RotateEntity sun,pitch#,yaw#,roll#
RenderWorld
Flip
Wend
End