Random Dungeons & Dragons Scripts
I love D&D. I've made a bunch of random generators that aren't quite covered with other websites.
Star System Generator
PLEASE NOTE: The sheer amount of information here makes it impossible to format the system generator for small screens. Please use this on a medium or higher screen for best display results.
I've been involved in star system generation code for quite a while. There was one in particular that offered everything I needed: Aina's Star Generator.
Unfortunately Aina stopped updating the code over twenty years ago and can no longer be reached. He published his code base online back in the day so others could use and improve it.
Here we are in the here and now. I've updated his code to work with php and have made quite a number of modifications. The goal is to make a few tweaks here and there and test out the random generator in a gravity simulator like Universe Sandbox 2 to see just how viable these star systems are.
temperatures: planet temperatures are seriously out of whack. I've left them in until I can figure out the problem.
System Summary
orbit | description | mass | radius | ecc | inc | moons |
---|---|---|---|---|---|---|
primary | K8V : Orange Dwarf (M-S) | 0.5548 sol | 1.307 sol | |||
0.141 au | Rock | 0.01669 earth | 1,629 km | 0.02 | 1° | 0 |
0.436 au | Ice Ball | 1.07618 earth | 11,171 km | 0.04 | 10° | 2 |
1.222 au | Ice Ball | 1.92128 earth | 11,839 km | 0.03 | 16° | 3 |
2.322 au | Gas Giant | 2.34110 earth | 14,475 km | 0.05 | 7° | 8 |
7.197 au | Ice Ball | 0.20356 earth | 6,413 km | 0.17 | 2° | 0 |
Full System Details
Star 1: K8 V Orange Dwarf (M-S)
Mass | 0.5548 sol |
Diameter | 1.307 sol |
Temp | 3,965°K (Lux: 0.0947 sol) |
Age | 10,999.989 Myears (MAX: 58,558.594 Myears) |
Orbits | min: 0.031 AU inner max: 0.252 AU life max: 0.369 AU max: 22.192 AU |
Planet 1 - Inner Zone - Rock - Rocky | |
Orbit | dist: 0.141 AU period: 2.49 earth days Ecc: 0.02 Inc: 1° |
Body | rad: 1629 km mass: 0.017 earth grav: 0.256 earth rot: 59.771 hours tilt: 35° |
Temperatures | avg: 1,354.516°C day: 1,373.219°C night: 1,219.064°C |
Water Type: | Rare Ice - 1% |
Atmosphere | type: Very Thin pres: 0.028 atm comp: Carbon Dioxide oxyg: 0 |
Mineral Resources | Metal Ore: 1 Radioactive Ore: 1 Precious Metals: 1 Raw Crystals: 1 Precious Gems: 1 |
Planet 2 - Outer Zone - Ice Ball - Icy | |
Orbit | dist: 0.436 AU period: 109.17 earth days Ecc: 0.04 Inc: 10° |
Body | rad: 11171 km mass: 1.076 earth grav: 0.351 earth rot: 2,620.004 hours tilt: 18° |
Temperatures | avg: 613.103°C day: 619.742°C night: 521.137°C |
Water Type: | Ice - 28% |
Atmosphere | type: Thin pres: 0.186 atm comp: Carbon Dioxide oxyg: 0 |
Mineral Resources | Metal Ore: 1 Radioactive Ore: 1 Precious Metals: 1 Raw Crystals: 1 Precious Gems: 1 |
Moons | |
Moon 0: | core: Icy orbit: 1117100 km incline: 1° ecc: 0.02 radius: 2910 km mass: 0.038046769078316 earth tilt: 15° |
Moon 1: | core: Rocky orbit: 223420 km incline: 4° ecc: 0.02 radius: 500 km mass: 0.00062723775182251 earth tilt: 27° |
Planet 3 - Outer Zone - Ice Ball - Icy | |
Orbit | dist: 1.222 AU period: 683.41 earth days Ecc: 0.03 Inc: 16° |
Body | rad: 11838.5 km mass: 1.921 earth grav: 0.557 earth rot: 16,401.803 hours tilt: 30° |
Temperatures | avg: 397.697°C day: 401.665°C night: 338.042°C |
Water Type: | Ice - 23% |
Atmosphere | type: Thin pres: 0.304 atm comp: Carbon Dioxide oxyg: 0 |
Mineral Resources | Metal Ore: 19.5155 Radioactive Ore: 11.5155 Precious Metals: 1 Raw Crystals: 1 Precious Gems: 1 |
Moons | |
Moon 0: | core: Icy orbit: 710310 km incline: 2° ecc: 0.17 radius: 3279 km mass: 0.040824824734716 earth tilt: 25° |
Moon 1: | core: Rocky orbit: 710310 km incline: 10° ecc: 0.0 radius: 3417 km mass: 0.10779827235546 earth tilt: 37° |
Moon 2: | core: Rocky orbit: 213093 km incline: 20° ecc: 0.04 radius: 500 km mass: 0.00043424152049251 earth tilt: 45° |
Planet 4 - Outer Zone - Gas Giant - Icy | |
Orbit | dist: 2.322 AU period: 1,975.72 earth days Ecc: 0.05 Inc: 7° |
Body | rad: 14474.5 km mass: 2.341 earth grav: 0.454 earth rot: 47,417.288 hours tilt: 30° |
Temperatures | avg: -25.000°C day: -24.885°C night: -5.000°C |
Water Type: | Crystals - 1% |
Atmosphere | type: Massive pres: 47.711 atm comp: Methane/Ammonia/Hydrogen oxyg: 0 |
Mineral Resources | Metal Ore: 1 Radioactive Ore: 1 Precious Metals: 1 Raw Crystals: 1 Precious Gems: 1 |
Characteristics | Cloud Cover |
Moons | |
Moon 0: | core: Rocky orbit: 1736940 km incline: 5° ecc: 0.04 radius: 3362 km mass: 0.13201231923902 earth tilt: 17° |
Moon 1: | core: Icy orbit: 1157960 km incline: 4° ecc: 0.09 radius: 1792 km mass: 0.006663679409111 earth tilt: 35° |
Moon 2: | core: Icy orbit: 1736940 km incline: 8° ecc: 0.02 radius: 2333.5 km mass: 0.024522923549055 earth tilt: 22° |
Moon 3: | core: Icy orbit: 1592195 km incline: 1° ecc: 0.03 radius: 1596 km mass: 0.0031383941162402 earth tilt: 36° |
Moon 4: | core: Icy orbit: 289490 km incline: 9° ecc: 0.04 radius: 3193.5 km mass: 0.037713847482116 earth tilt: 41° |
Moon 5: | core: Rocky orbit: 1736940 km incline: 7° ecc: 0.08 radius: 1426 km mass: 0.0067156592354042 earth tilt: 46° |
Moon 6: | core: Icy orbit: 578980 km incline: 7° ecc: 0.05 radius: 1340.5 km mass: 0.0037191121137828 earth tilt: 45° |
Moon 7: | core: Icy orbit: 2026430 km incline: 7° ecc: 0.03 radius: 2230.5 km mass: 0.01285010752398 earth tilt: 18° |
Planet 5 - Outer Zone - Ice Ball - Icy | |
Orbit | dist: 7.197 AU period: 3,179.83 earth days Ecc: 0.17 Inc: 2° |
Body | rad: 6412.5 km mass: 0.204 earth grav: 0.201 earth rot: 8.014 hours tilt: 45° |
Temperatures | avg: 177.209°C day: 179.825°C night: 159.488°C |
Water Type: | Ice - 55% |
Atmosphere | type: Very Thin pres: 0.022 atm comp: Carbon Dioxide oxyg: 0 |
Mineral Resources | Metal Ore: 18.825 Radioactive Ore: 1 Precious Metals: 1 Raw Crystals: 1 Precious Gems: 1 |