Modding Help Tiled: WTH is going on...

Discussion in 'Starbound Modding' started by Tremerion, Aug 16, 2016.

  1. Tremerion

    Tremerion Existential Complex

    Ok. I tried whole day to get my head over Tiled and making dungeon/instance world. I have working everything except .json file.

    If I place a renamed version of vanilla dungeon, it works great, teleports my character and all. But if I add o delete objects or block in Tiled and save it, then boom, teleporting back to ship. Log shows this:

    [Info] UniverseServer: Warping player 1 to InstanceWorld:galacticmarket:-:-
    [Info] UniverseServer: Warping player 1 failed, invalid world 'InstanceWorld:galacticmarket:-:-' or world failed to load
    [Info] UniverseServer: Clearing broken world InstanceWorld:galacticmarket:-:-

    Anyone knows wth is going on with Tiled?
     
  2. Charlatan

    Charlatan Parsec Taste Tester

    Does your map work if it only uses front and back, as in no objects/wiring etc. ?

    If so I've got the same problem and Log Entry - trial and error clearly shows my map works when its only blocks and produces the error when an object is present.
     
  3. Tremerion

    Tremerion Existential Complex

    No, my map is not working, ever. I've even tried expample dungeon from Modding Tutorial for Tiled. Stupid Tiled cannot open this file... So tutorial can kiss my ass. But example dungeon is working in game. But if I cannot edit it then what is the point...
     
  4. Charlatan

    Charlatan Parsec Taste Tester

    What exactly is the error? Something about tileset not found?

    Tiled will only understand to find them if:

    1) Your mod is in ...Starbound\giraffe_storage\mods
    2) You unpacked the assets into ...Starbound\assets\packed
     
  5. Tremerion

    Tremerion Existential Complex

    I know. I've placed unpacked game files in Starbound\assets\packed, Tiled is reading them, but even when I place exampledungeon iside packed\dungeons it gives me error about Tiles not found. It will read my own dungeon, but still after saving it, game is not teleporting character there. Tiled must somehow mess the file coding.
     
  6. origamania

    origamania Subatomic Cosmonaut

    What version of Tiled are you using?
     
  7. Inf_Wolf14

    Inf_Wolf14 Parsec Taste Tester

    Same. The more updated versions of Tiled have one key game-breaking difference...

    When you place any objects in you Tiled map, for them to load, Starbound requires a "properties" key to be present for every object, even if it is empty.
    The Tiled dev updated the software so that it excludes "empty" properties. In the Json file for your dungeon, check if every object has a "properties" key. If not, there's your problem.

    I used to use a find, replace macro to add the key to every object; However, if you downgrade Tiled to a previous release, (version 14.0 and lower I think), this will no longer occur.

    There's a couple other thread floating around this sub-forum on the same subject if youre willing to search them up.
     
    Raindrac likes this.
  8. origamania

    origamania Subatomic Cosmonaut

    0.15.2 is the latest working version. Any later and the properties disappear.
     
    Inf_Wolf14 likes this.
  9. Tremerion

    Tremerion Existential Complex

    Thx for info. Now my maps load properly. But not all objects all visible in game. They are set to be visible, I can see them and edit them in Tiled, but game does not load them all. Strange. I think I will try to make my map in paint.
     
  10. Mackinz

    Mackinz The Waste of Time

    Making png dungeons is more of a hassle than it's worth. Work with Tiled instead and use starbound.log to figure out what's going on with those objects.
     
  11. Inf_Wolf14

    Inf_Wolf14 Parsec Taste Tester

    Are you placing them in the object layer? Not the front/back tile layer?
    Also good to hear you got it loading at least.
     
  12. Tremerion

    Tremerion Existential Complex

    Yes, they are placed in object layer. Only teleporter is visible in current test.
    code:
    Code:
    "color":"#ff0000",
      "draworder":"topdown",
      "height":0,
      "name":"objects",
      "objects":[
      {
      "gid":6925,
      "height":76,
      "id":796,
      "name":"teleporter",
      "properties":
      {
    
      },
      "rotation":0,
      "type":"",
      "visible":true,
      "width":42,
      "x":104,
      "y":296
      },
      {
      "gid":2147486492,
      "height":48,
      "id":808,
      "name":"",
      "properties":
      {
    
      },
      "rotation":0,
      "type":"",
      "visible":true,
      "width":63,
      "x":303,
      "y":210
      },
      {
      "gid":2147486493,
      "height":48,
      "id":809,
      "name":"",
      "properties":
      {
    
      },
      "rotation":0,
      "type":"",
      "visible":true,
      "width":88,
      "x":288.666666666667,
      "y":295.333333333333
      },
      {
      "gid":4007,
      "height":40,
      "id":810,
      "name":"",
      "properties":
      {
    
      },
      "rotation":0,
      "type":"",
      "visible":true,
      "width":24,
      "x":320.666666666667,
      "y":246.666666666667
      }],
    
    As you can see there are other objects placed, but they are not visible in game. This program is seriously pain in the ass.
     
    Last edited by a moderator: Aug 23, 2016
  13. Mackinz

    Mackinz The Waste of Time

    Probably because only the "teleporter" Is defined and the rest are not. Look at each "name" line.

    Try replacing the objects you say you have placed in Tiled.
     
  14. Tremerion

    Tremerion Existential Complex

    Ok. It seems to work now. But adding "names" did nothing. When I changed all "y" values to 296(teleporters y), objects are visible now. Now time to figure out how to add my modded objects :)
     
  15. Inf_Wolf14

    Inf_Wolf14 Parsec Taste Tester

    Its easier to make the tilesets for your modded objects first. I finished mine for my race mod, so now its pretty straightforward.
    I can help a little if you need any with making them.
     
  16. Tremerion

    Tremerion Existential Complex

    Yes. I need help with it. I've tried to make tileset but my world is not working when adding modded object. Can you give me clues to how properly add an object to tileset?
     
  17. Inf_Wolf14

    Inf_Wolf14 Parsec Taste Tester

    How I go about it is to add a blank tileset in Tiled. (Map>New Tileset...)
    1. Choose the option for 'Collection of Images'.
    2. Select your new tileset, and press the plus in the tools. (Add Tiles)
    3. Select the image of the object you want to add. (One at a time sadly)
    4. Continue adding until you have all the ones you want. Then comes the pain...
    5. For every object, you have to add the custom properties. Including the imagePositionX, imagePositionY, object, etc... (Take a look at the properties of vanilla tilesets to get an idea.) (Or another alternative, is to export the tileset now with 'Export Tileset As' in the tileset tools. Then add the properties in that .json file.)

    Once you have everything you want, export the tileset. (Or just save the file if you already exported it from above.)

    Might've missed something, not sure, but I doubt I got that perfect the first time. ^
    If I did, call me out. I have a working custom tileset, so I know I can make it work. :)
     
  18. Tremerion

    Tremerion Existential Complex

    I was doing step by step by your instruction. It seems to work, partialy. Tiled is reading tileset without errors, I've added parameters to one object for now. But in game world is not working with it. Without this modded objects all is fine. I want to make instance world for my mod Galactic Shops.
    Code after exporting:
    Code:
    { "columns":0,
    "margin":0,
    "name":"galacticshops",
    "spacing":0,
    "tilecount":1,
    "tileheight":32,
    "tileproperties":
      {
      "0":
      {
      "\/\/description":"Buy Apex Furniture",
      "\/\/name":"apexshop",
      "\/\/shortdescription":"Apex Shop",
      "imagePositionX":"-24",
      "imagePositionY":"0",
      "object":"apexshop",
      "tilesetDirection":"right"
      }
      },
    "tilepropertytypes":
      {
      "0":
      {
      "\/\/description":"string",
      "\/\/name":"string",
      "\/\/shortdescription":"string",
      "imagePositionX":"string",
      "imagePositionY":"string",
      "object":"string",
      "tilesetDirection":"string"
      }
      },
    "tiles":
      {
      "0":
      {
      "image":"..\/..\/..\/Program Files (x86)\/Steam\/steamapps\/common\/Starbound\/mods\/Galactic Shops by Tremerion\/objects\/crafting\/apexshop\/apexshop.png"
      }
      },
    "tilewidth":133
    }
     
    Last edited by a moderator: Aug 23, 2016
  19. Inf_Wolf14

    Inf_Wolf14 Parsec Taste Tester

    Unsure why yours is looking so wierd...
    Heres mine for comparison:
    Code:
    {
      "columns" : 0,
      "margin" : 0,
      "name" : "objects-by-race\/greckan",
      "properties" : {},
      "spacing" : 0,
      "tilecount" : 1,
      "tileheight" : 40,
      "tileproperties" : {
        "0" : {
          "//description" : "A bookcase for storing folk tales and legends...",
          "//name" : "scholarbookcase",
          "//shortdescription" : "Scholar's Bookcase",
          "imagePositionX" : "0",
          "imagePositionY" : "0",
          "object" : "scholarbookcase"
        }
      },
      "tiles" : {
        "0" : {
          "image" : "..\/..\/..\/tiled\/packed\/objects\/scholarbookcase.png"
        }
      },
      "tilewidth" : 64
    }
    
    Did you export it as a .json file? Not the other option? Never seen all that propertiy formatting before...
     
  20. Tremerion

    Tremerion Existential Complex

    I will try to edit your and see waht will happen. I've exported it as json. Tiled is strange program lol
     
    Inf_Wolf14 likes this.

Share This Page