Modding Help Translation of mods...

Discussion in 'Starbound Modding' started by Shychara, Jul 4, 2017.

  1. Shychara

    Shychara Void-Bound Voyager

    Hello! I would like to learn how to make a "translation" for mods. I've already seen that it can be done, but I'm interested in how and where to read, so that everything would be clear. Just direct me to the right place and the right page and I'll leave right away. Thank you in advance! :nuruwink:
     
  2. bk3k

    bk3k Oxygen Tank

    Well it shouldn't be too hard. First off, you'll want to learn how to patch files, so I suggest reading this thread
    http://community.playstarbound.com/threads/basic-patching-now-with-path-guide-v1-9.84496/
    and there is a patch maker here - http://chbrown.github.io/rfc6902/
    That can make your life much easier

    For the most part you'd be patching descriptions. But also you'd probably need to patch "labels" and such in the interfaces. Mostly you would -
    go through the mod's assets looking for things needing translated.
    Make a copy of the files (that need translated) elsewhere, and edit the copy.
    Put the original and the edited copy into that patch maker :D
    The patch it outputs will have the same path and name as the original... almost. You add .patch to the filename.

    Now one other important thing is controlling load order. You can do that with your _metadata file. Lets say you want to translate my inventory mod for example. You'd see in my _metadata file this line.
    Code:
    "name" : "bk3k_inventory",
    
    So for your _metadata you'd add this somewhere in the middle.
    Code:
    "includes" : [ "bk3k_inventory" ],
    
    or
    Code:
    "requires" : [ "bk3k_inventory" ],
    
    Either way would force your mod to load after mine, thus your mod patches my files. It would be useless to try to patch the files before they're added, so that's why your mod needs to load after.

    edit:
    You might be wondering why I linked you to a thread that teaches you patching, when also linking a tool to do it for you. The reason is that you should understand how this works, and what the tool is doing. For the same reason you should know how to do math even if you have a calculator.
     
    Last edited: Jul 4, 2017
    Shychara, Cyel and The | Suit like this.

Share This Page