Modding Help JSON problem with recipe

Discussion in 'Starbound Modding' started by Campaigner, Dec 22, 2013.

  1. Campaigner

    Campaigner Giant Laser Beams

    EDIT: SOLVED

    I'm trying to add a new item to the game, which I've successfully done multiple times now, but I'm getting JSON errors for some reason. I'm not sure why it's doing this, but the starbound log shows that I've got a json issue. The exact issue is as follows;

    caused by: JsonParsingException: Cannot parse json file: /recipes/campworks_bottleflame.recipe
    caused by: JsonParsingException: Error parsing json: bad object, should be '{' at 2:3

    The recipe file shows this:
    This is a DIRECT copy of another recipe from the base game. So, doing as it says, I change the [ next to input to {,

    and the recipe still does not show up. This line shows up again;

    caused by: JsonParsingException: Error parsing json: bad object, should be '{' at 2:3

    This is the only thing in the log file that shows up related to this item. The object file is a carbon copy of the oil lantern, the frames copy is the same thing, all files are named appropriately, but this one thing which makes no sense is preventing me from using this object. What's wrong?
     
    Last edited: Dec 22, 2013
    iAmGalaxy likes this.
  2. Campaigner

    Campaigner Giant Laser Beams

    I just deleted the recipe file and copied from another of my mods, and it fixed itself. Funny part is that it's EXACTLY the same as what I posted in the first post.

    JSON is garbage.
     
    zortbg likes this.
  3. zortbg

    zortbg Cosmic Narwhal

    Hi,
    sometimes the format is interpreting spaces before the curly braces by strange manner.
    Depending on the text editor you use those can be avoided, but i had same experience with one recipe file.
    Notepad ++ for the win!
    :)
     
  4. michealv

    michealv Industrial Terraformer

    Agreed, Notepad++ is fantastic, move your cursor over a { and it highlights in red, where the corresponding bracket is, fantastic for debugging
     
    zortbg likes this.
  5. zortbg

    zortbg Cosmic Narwhal

    Thanks for the likes, guys :)
     

Share This Page