Modding Help Simple Mod: Add More Planets, Automatic Asteroid Field

Discussion in 'Starbound Modding' started by simulatoralive, Apr 18, 2017.

  1. simulatoralive

    simulatoralive Existential Complex

    What I would like to build is a very small mod for personal use that does three things: increase the average number of planets in each system, put an asteroid field on the outer edge of each system with at least a 90% chance and increase the number of moons/orbiting planets that each gas giant has, guaranteeing at least two. If I could also increase the maximum number of moons for gas giants, that would be awesome.

    Problem is I've never done anything quite like this with Starbound. I've no idea how to make such changes. My previous mods involved adding new blocks and custom ships. I know I've got to patch celestial.config, but I really do not know what the various variables do. I can guess, but I've no concrete answers.

    So, can anyone at least point me in the right direction?

    As for my reasons for wanting this: I recently spent a large amount of time searching for a fiery star system with three things: an ancient gate, a gas giant with 3 moons and at least 1 ocean planet, either water or poison. I did eventually find one that fit. I wish it also had an asteroid field (this was on my list of desirable extra features).

    I find that Starbound's idea of what a star system is is very lacking. Lets face it, our own star system (Sol) is utterly chock full of planets (8 or 9, depending on opinion) and asteroid fields. If you include the Kuiper belt, that's an extra asteroid field out on the outskirts and from what I gather, floating rocks are extremely common in space, not a rarity, especially out on the edge of a system.

    Edit: Started digging through celestial.config and I'm starting to see this will not be all that simple at all. I'm seeing each orbit has a weighted average chance of being occupied. So, I'd have to patch things in dozens of places. Erg.

    Edit 2: Well, I've at least figured out how to give gas giants guaranteed orbiting bodies. One tiny patch did the job. Now to see if I can give them more...
     
    Last edited: Apr 18, 2017
  2. bk3k

    bk3k Oxygen Tank

    Some good references for you

    Truespace - I suspect you'll probably like this mod on its own merits too. It is a pseudo-realistic system generation overhaul. I highly recommend it.
    http://community.playstarbound.com/resources/truespace.3785/

    and my variable planet size mod
    http://community.playstarbound.com/resources/bk3ks-variable-planet-sizes.4476/

    you would see in both cases how the systems can be edited. Truespace is probably particularly useful in this way because they're re-defining the "belts" themselves, how many in different system types, what goes in that belt, etc.

    My mod this can (optionally) compliment TS. And where that's useful to you is how I'm replacing "variationParameters". For primary orbit slots I use this

    Code:
          [
            {
              "imageScale" : 0.1,
              "smallImageScale" : 0.5,
              "worldSize" : "medium"
            },
            {
              "imageScale" : 0.15,
              "smallImageScale" : 0.6,
              "worldSize" : "large"
            },
            {
              "imageScale" : 0.21,
              "smallImageScale" : 0.70,
              "worldSize" : "huge"
            },
            {
              "imageScale" : 0.27,
              "smallImageScale" : 0.75,
              "worldSize" : "mega"
            },
            {
              "imageScale" : 0.32,
              "smallImageScale" : 0.80,
              "worldSize" : "immense"
            }
          ]
    
    but for satellite orbits
    Code:
          [
            {
              "imageScale" : 0.075,
              "worldSize" : "medium"
            },
            {
              "imageScale" : 0.035,
              "worldSize" : "small"
            },
            {
              "imageScale" : 0.045,
              "worldSize" : "small"
            },
            {
              "imageScale" : 0.055,
              "worldSize" : "small"
            },
            {
              "imageScale" : 0.025,
              "worldSize" : "verysmall"
            }
          ]
    
    I made the size range of satellites smaller than the range of the main orbits because that just makes sense.

    I don't differentiate on the different planet definition types that way, but I could... or you could. You can get pretty intricate if you want. You might find it useful to utilize my mod as a starting point - yet edited to suit your purposes (perhaps while cutting out aspects you may not want like larger planet sizes, staggered gravity, etc).

    One thing though - you can edit a lot of different properties on different steps. Hard to explain but once you've looked at the file for a while you'll see what I mean. It is pretty versatile.
     
  3. simulatoralive

    simulatoralive Existential Complex

    Ah. This is fun and so pretty. So very pretty. That's the main reason I wanted a gas giant with lots of moons. For the view outside my base. :)

    I've got gas giants with larger numbers of moons working already. Turns out that was really easy. I've currently got the max set at 5, but I think I'll experiment with punching it up to 8 next...

    Found a gas giant with five moons and took some screen shots. One from the navigation panel and one from the surface of one of the orbiting planets.
     

    Attached Files:

  4. simulatoralive

    simulatoralive Existential Complex

    Well, I seem to have found Starbound's limit on displaying moons on gas giants, at least from the navigation panel: 6. Any more than that and the sucker crashes to desktop.

    Now, to my mind, that's just sad. Jupiter has how many moons? Let's just go with lots more than 6.

    I suppose Starbound could just be showing us the largest 6 and ignoring lone asteroid moons, right? Hehe.

    Oh well. At least I was able to increase the number of available planetary bodies..
     
  5. simulatoralive

    simulatoralive Existential Complex

    Heh. That was not as hard as I expected. I've just never been too good with patching. Guess I just needed a little practice.

    Got a very basic vanilla compatible version working that does everything I want except to add that outer asteroid field.

    Now that I've got a clue what I'm doing, that shouldn't be too hard.

    Edit: Now that's done, too. Hrm. To post it or work on TrueSpace compatibility? Either way, will have to wait for tomorrow.
     
    Last edited: Apr 18, 2017
  6. DraikNova

    DraikNova Spaceman Spiff

    Seems nice. I wonder whether a solution to the "only a limited number of moons" issue would be to make a mini-moons biome that looks somewhat like a more grouped asteroid biome. But I'm not sure how easy that would be to do.
     
  7. simulatoralive

    simulatoralive Existential Complex

    Well, a little beyond my skills. Kind of like the idea, though.
     
  8. simulatoralive

    simulatoralive Existential Complex

    Took a close look at TrueSpace's celestial.config.patch file and found the chance of planets occurring to be close enough to what I'm doing to leave it alone. 66% (TrueSpace) vs. 50%-75% (what I'm doing), with vanilla clocking in at 25%-50%. Those percentages vary based on which orbit(s) we're talking about.

    Also found I really don't like TrueSpace. Total surprise to me. I was expecting to love it.

    Anyhoo, I can confirm that my changes to gas giants work with TrueSpace out of the box.

    I'm going to post my new mod momentarily.

    After that I'll have to play with UniGen and see if I like it or at least parts of it.
     
  9. simulatoralive

    simulatoralive Existential Complex

    BTW, I posted the mod here:
    http://community.playstarbound.com/resources/more-planets.4679/

    I tried also this out on a new search for that ideal system I wanted. Five minutes and I had one with better features than the original. Five minutes, as opposed to the 2-3 hours the first time.

    Then I went looking for another, in case I got something even more ideal. I think it was ten minutes that time.

    For the record, that was a fiery system with a gas giant (including at least 3 moons), an ocean planet (toxic, frozen or regular) and an ancient gate. The optional extras were a magma ocean planet and an asteroid field.

    So, in short, mission successful. This mod will help you find that ideal system you've been dreaming of, though you'll have to put forth the time to search manually.

    I wish there was a search system that would scan for a particular set of conditions... Hrm. Wonder if that would be possible with Lua. Anyone wanna build a long-range scanner mod?
     

Share This Page