Thanks.
Here's the latest version (with which you can make different-coloured galaxies):
I have supplied it in function form so that you can use it easier.
function galaxy(Xcentre as double float, Ycentre as double float, pixwidth as double float, pixheight as double float, t as integer, s as double float, v as integer, u as double float, arm as double float, colorshift as dword)
INK RGB(255,255,255),0
a as double float
b as double float
c as double float
redshift as integer
greenshift as integer
blueshift as integer
xcoord as integer
ycoord as integer
rdiff as integer
gdiff as integer
bdiff as integer
height as double float
width as double float
redshift=RGBR(colorshift)
greenshift=RGBG(colorshift)
blueshift=RGBB(colorshift)
height = pixheight/200
width = pixwidth/200
LOCK PIXELS
For x = 1 to v
a = rnd(10000.0)/1000.0 : b=a*a : c=rnd(3600.0)
b=(b*SIN(c*t))*INT(rnd(3))*arm/300.0
c=c+(u*SIN(rnd(10000)))
If b<0 then b=0
xcoord=(b*width*SIN(c+s*b))+xcentre
ycoord=(b*height*COS(c+s*b))+ycentre
rdiff=40000/((b)^1.5)
gdiff=40000/((b)^1.5)
bdiff=40000/((b)^1.5)
bdiff=bdiff+blueshift
gdiff=gdiff+greenshift
rdiff=rdiff+redshift
If rdiff>255 then rdiff=255
If gdiff>255 then gdiff=255
If bdiff>255 then bdiff=255
DOT xcoord,ycoord,RGB(rdiff,gdiff,bdiff)
Next x
BOX xcentre-2,ycentre-2,xcentre+2,ycentre+2
unlock pixels
`An impressive galaxy in just 20 lines of code!
`s = spiral intensity (higher means it is more curved)
`t = number of arms
`u = edge width of arms (higher means it blends in better)
`v = number of stars in galaxy (100000 is optimal)
`arm = arm length (in percent), 100 is optimum
`width = galaxy width (5 = width of screen when arm = 100%)
`height = galaxy height (3.75 = height of screen when arm = 100%)
endfunction
Your signature has been erased by a hyper-intelligent pan-dimensional being (a mod)