Modding Help [Solved] My Vanity Mod doesn't work. Pls help

Discussion in 'Starbound Modding' started by Endercoloss, Jan 27, 2017.

  1. Endercoloss

    Endercoloss Void-Bound Voyager

    hi i just tried to create my first mod but when i try to run it the game crashes. I tried a lot of different things but none worked. If someone has an idea what I should change to let it work please let me know.

    I attached the file so anyone can download it.

    In case it wasn't clear it WILL make your game crash
     
  2. The | Suit

    The | Suit Agent S. Forum Moderator

  3. Endercoloss

    Endercoloss Void-Bound Voyager

    The log says : "Could not read json asset /items/armors/icearmorcool/icearmorcool.head"
    I don't know how to fix this.
     
  4. lazarus78

    lazarus78 The Waste of Time

    Probably a syntax error. Post the json.
     
  5. Endercoloss

    Endercoloss Void-Bound Voyager

    Here is it.
     

    Attached Files:

  6. lazarus78

    lazarus78 The Waste of Time

    Remove the , at the end of the 3rd to last line.
     
  7. Endercoloss

    Endercoloss Void-Bound Voyager

    removing the , at the end of the 3rd last line actually did not change the situation
     
  8. lazarus78

    lazarus78 The Waste of Time

    Then something else is wrong. That was the only syntax error. Could be you just set it up wrong all together.
     
  9. Endercoloss

    Endercoloss Void-Bound Voyager

    maybe it's just me, probably because well it is my first try at modding ever
     
  10. lazarus78

    lazarus78 The Waste of Time

    Pack up everything and ill take a look at it.
     
  11. Endercoloss

    Endercoloss Void-Bound Voyager

    Here
     

    Attached Files:

  12. lazarus78

    lazarus78 The Waste of Time

    Just a note, when you are working on mods, putting it into a pak file is kinda counterproductive. Just zip up the folder of the mod.
     
  13. Endercoloss

    Endercoloss Void-Bound Voyager

    k sry i thought you meant with pack up to put it in a pak file
     
  14. lazarus78

    lazarus78 The Waste of Time

    Personally I never use that format. I think it is only necessary for the workshop.


    Anyhoo, your issue stems from every other armor piece having the same issue as the head item. Also, your recipie files are missing closing brackets. AND, your patch file is missing commas after each section.

    You should really read up on JSON syntax.
     
  15. Endercoloss

    Endercoloss Void-Bound Voyager

    k i fixed the brackets of the recipes files.
     
  16. lazarus78

    lazarus78 The Waste of Time

    Here is a, more or less, fixed version.
     

    Attached Files:

  17. Endercoloss

    Endercoloss Void-Bound Voyager

    Thanks a lot.

    Btw i am just curious what exactly did you change?
     
  18. lazarus78

    lazarus78 The Waste of Time

    Removed the offending comma from the armors, added the missing brackets to the recipes, and added the missing commas to the player.config.patch file.

    And because I am a stickler for it, I also cleaned up the formatting of the files, but that is irrelevant to the function of the mod.

    Remember, most of modding is tinkering and learning from what you see, so don't be afraid to dig into things just to see how they work. Make mistakes, and success will come later.
     
  19. Endercoloss

    Endercoloss Void-Bound Voyager

    since i'm new to modding could you explain to me what an "offending" comma is ( i pretty much am not great in english since it isn't my native language) and what formatting means ?
     
  20. lazarus78

    lazarus78 The Waste of Time

    In JSON, all lines of code must end in a comma.

    Example:
    Code:
    {
      "itemName" : "ChestAug01",
      "price" : 7500,
      "rarity" : "Legendary",
      "category" : "fabricantaugment01",
      "tooltipKind" : "fabricantaugment",
      "inventoryIcon" : "lightaugment.png",
      "description" : "An EPP module that enables a survival pack to emit a strong light.",
      "shortdescription" : "Light III Augment",
    
      "augment" : {
        "type" : "chest",
        "name" : "light3",
        "displayName" : "Light III",
        "displayIcon" : "/items/augments/chest/FabricantAugment01.png",
        "effects" : [ "lightaugment3" ]  <----- No comma
      }, <----- Comma showing the end of a block of code, but it is not the last block, so it needs a comma.
    
      "radioMessagesOnPickup" : [ "pickupaugment" ],
    
      "scripts" : [ "/scripts/augments/augment.lua" ] <----- No comma
    } <----- No comma
    
    Notice how every line has a comma at the end save for a few. Only the last line in a block of code does not require a comma.


    Seems confusing at first, but you will get the hang of it in time.

    This site is great for checking for syntax errors: http://jsonlint.com/
     

Share This Page