While working on the equipment selection screen, I realized something. In order to have custom technologies which includes colony base technologies, I will have to specify which planets a colony base can settle. Since those types of planets are hard-coded in the game, it'd be easy to make mistakes and cause the colony bases to be useless because spelling don't match.
This led me to think, what if I make the planet types non-hardcoded? I can separate the planets art into its own graphic file, then have a XML file "planets.xml" that contains name of the type of planet, description of that type, pollution threshold, type that it degrades to, and type that it terraforms to (if any), max population range, and where in the planets.png the planet art is located. It will always be 40x40 since the UI in game expects that size, but you can make different sized that is under 40x40. Also, more than one planet can use the same art.
This will allow users to create really unique planets for their mods, rather than just replacing the artwork.
While thinking about the planets, I realized another thing. Star Systems are hard-coded as well, it have a pre-set probability for types of planets to show up in its system (all different colors have the same probability). I can change star systems to use XML file instead of hard-coded. There would be different types of stars (colors, black hole, etc). Again, I would separate the star artwork from the artwork into its own file: stars.png. The XML file would determine which graphic to use, color of the star, probability range for different types of planets, and whether or not this kind of star allows planets (black holes don't have planets for example). This would allow users to create different stars, rather than just being limited to the normal one and black hole. For example, quastars or binary star systems.
So with the above system, you could designate yellow stars to have more organic planets (terran, jungle, ocean, etc), and designate red stars to have more mineral rich planets (you can specify the probability range of bonuses as well)
The amount of planets will still be adjustable in-game, just that their types would be determined by stars.xml file's probability range. However, if I were to convert to the xml file for stars, I will need to remove the black hole slider, since it will be determined by the xml file/galaxy script.
I will then also improve the galaxy script to actually specify which type of star to add when generating galaxy. Currently it just says "size 2 star here, size 3 star there", then the game randomly picks a percentage of stars and change them to black holes based on your percentage selection.
I think this should improve the game a lot, and allow me to more easily modify things without having to change the code inside the game. One of my goal is to make this game very easy to mod, and I realized that just changing the artwork may not be enough for some people, so I hope this will help satisfy the modding desire of those people :)