1. Please be advised of a few specific rules and guidelines for this section.

RELEASED Simple Mod Manager + Sample Mods

Discussion in 'Other' started by KrazyTheFox, Dec 6, 2013.

  1. KrazyTheFox

    KrazyTheFox Scruffy Nerf-Herder

    I figured that since this beta is going to be receiving rapid updates, I'd need some tools to help keep any mods I have organized, and I'd also need a way to make sure updates don't break mods by overwriting files.

    To that end, I present some (extremely basic) files to help with this. Currently, you can only install this to a specific directory and it has only been tested on Windows. I plan to fix this soon, but for now everything is hard-coded.

    You will need:
    - Windows. Probably.
    - Java (the latest update is always preferable)
    - A brain. I'm not offering lots of support until I make this more user-friendly. Use some common sense and don't be too disappointed if it doesn't work.

    To "install":
    - Copy the contents of the .zip file into a new folder called "mods" inside your Starbound directory.
    - Make sure you remove all mods from your game's assets folder. You'll want that to be clean. You can copy these elsewhere for safe keeping.
    - Disable automatic updates in Steam
    - Run "GenerateManifest.bat" first. This will index all of Starbound's asset files.
    - Run "CreateModFolders.bat" next. This copies the file structure of the asset folder to put your mods in. DO NOT run this after adding mods to the folders. It WILL delete them. There is no safety mechanisms built into this yet.
    - And now you're done and ready to start modding!

    To use:
    - Add your mods to the appropriate folders in the "assets-modded-files" folder.
    - To install your mods, run "AddMods.bat". This backs up the original game files and replaces them with the modded ones. It will also add any new files your mod contains. If you have any mods installed already, REMOVE THEM FIRST, otherwise you will overwrite your backups with modded files.
    - To remove your mods and restore your game to its vanilla state, run "RemoveMods.bat".
    - Remember how you disabled automatic updates? Good! Every time there's a new update for the game, remove your mods (they won't be deleted—how awesome is that?), then update the game. After the update is complete, run "CompareManifest.bat". This will show you which assets have changed during the update. Use this list to check for any mod conflicts. Once you're sure nothing broke (or you've fixed things), go ahead and add your mods back into the game ("AddMods.bat").
    - Don't forget to generate a new manifest after updating the game and before installing your updated mods.

    To download:
    - Check the files attached to this post. If you don't trust me and want to see the source code for yourself, I've attached that as well. Once I get this to a more presentable state, I'll also be putting the code up on github.
    - The .bat files allow you to see the output of the programs. If these give you an error about "java" not being recognized, edit them to include the full path to the java.exe executable or add java to your environment variables.

    Any problems? Let me know! If you don't have any problems with it, I'd love to hear about that, too.

    Sample Mod (More to come):

    High-Tech Chest Expander
    This mod expands the High-Tech Chests to have 40 slots instead of the standard 16. READ THE INSTRUCTIONS in the archive before installing. Download is attached to this post.

    This mod also adds a 40 slot chest layout file, the same size as one inventory pane, as seen below:


    Last Updated: December 6, 2013 - 01:45AM EST

    Attached Files:

    Last edited: Dec 6, 2013
    PolarStar likes this.
  2. PolarStar

    PolarStar Subatomic Cosmonaut

    Wow...I'm very impressed! In a few short days we're already striving towards making modding easier, and figuring out the quirks. Good work on this mod manager, I'll give it a look later.
  3. Coffeeman

    Coffeeman Subatomic Cosmonaut

    Hey @KrazyTheFox if you ever want help developing this further I would be happy to help. Great job :up:
  4. KrazyTheFox

    KrazyTheFox Scruffy Nerf-Herder

    I've got a lot of work to do (temp job) in the next couple days, and that's why this is in such a rushed state. I wanted something I could use quickly instead of taking the time to make a proper mod managing program. Once I'm done with said work, I'll come back to this and give it some TLC in the GUI department and set up a .zip mod format instead of everything just getting tossed into the game's file structure. Once I'm to the point of getting the basics working, I'll put this up on github and would love any and all contributions. Right now it's just a bit too fragmented and messy for that.

    Ideally, I'd also like to figure out a way to avoid mod conflicts with things like loot tables. Right now any mod that adds loot will conflict with any other. I've got a few ideas, but any suggestions for this would be particularly useful.
  5. jordo

    jordo Aquatic Astronaut

    Here's some info that might help you out:

    There's actually some rudimentary support for adding and managing mods that add or change assets.

    In the same directory as each platform executable, there is a bootstrap.config file that lists asset packages. By default it only lists one (the main game's assets), but you can add more.

    Assuming "starbound/" is your root starbound directory (i.e. the directory containing the assets directory, starbound.log, etc):

    1. Create a starbound/mods/somemod/interface/windowconfig/ directory.
    2. Copy the file starbound/assets/interface/windowconfig/title.config to the directory you created.
    3. Edit starbound/mods/somemod/interface/windowconfig/title.config (e.g. change the values in mainMenuButtonsOffsets to move the buttons on the main menu around).
    4. Edit your bootstrap.config file for your platform (e.g. on OS X: starbound/Starbound.app/Contents/MacOS/bootstrap.config, adding your mod - it should look like this:

      "assetSources" : [
      "storageDirectory" : "../../../"
    Now when you run the game, the file from your mod will be used instead of the file from the assets directory.
  6. KrazyTheFox

    KrazyTheFox Scruffy Nerf-Herder

    That's actually really useful, thanks! That should simplify this immensely.

Share This Page