Easily fied.
null=make vector3(1)
do
position skySphereObj,camera position x(),camera position y(),camera position z()
if range3D(camera position x(),camera position y(),camera position z(),object position x(planet),object position y(planet),object position z(planet))<skySphereSize then show object planet else hide object planet
sync
loop
function range3D(ax#,ay#,az#,bx#,by#,bz#)
set vector3 1,ax#-bx#,ay#-by#,az#-bz#
result#=length vector3(1)
endfunction result#
You could have many many planets and scenic objects with this system, in addition VanB's method does exclude planets from popping into existence by using fog to obscure the object to black at the range of the skysphere, whilst the sky sphere itself is not affected by fog.
Pneumatic Dryll
