This Luau module can be used to procedurally generate spiral, bar, and elliptical galaxies, using normal distribution and star classification mass ranges to achieve a realistic-looking star type distribution; stars nearer their galactic cores will tend to be larger, hotter, and brighter O, A, and B classes, whereas stars out towards the edges will tend to be the smaller, cooler M, K, and G classes.
Some of the generated galaxies are shown below; the first two screenshots were taken after star types were added, and the other two images are from before, but give a sense of the kinds of galaxy clusters that can be generated.
A mistake in translating global to local coordinates produced these interesting results. Whilst they're not what I was going for, I kept this as a feature toggle (wackyMode) - this is a number, as opposed to a boolean, as it also affects generation scale.