{"author_link":"\/users\/ryan-wine","author_name":"Ryan Wine","author_uid":"ryan-wine","comments":[],"epoch":1556747796,"event":"LD44","format":"md","ldjam_node_id":155792,"likes":3,"metadata":{"p_key":"131855","p_author":"Ryan Wine","p_authorkey":"1146275","p_urlkey":"348049","p_title":"Faery Tales - Modding guide","p_cat":"LDJam ","p_event":"LD44","p_time":"1556747796","p_likes":"3","p_comments":"0","p_status":"WAYBACK","us_key":"1146275","us_name":"Ryan Wine","us_username":"ryan-wine","event_start":"1556236800","event_key":"75","event_name":"LD 44"},"node":{"_collation":{"body_sanitizer":"TextUtils::SanitizeHTML via existing importer","event":"LD44","removed_author":false},"_superparent":139254,"_trust":2,"author":146275,"body":"This is a modding guide for my game Faery Tales - https:\/\/ldjam.com\/events\/ludum-dare\/44\/faery-tales\n\n![Capture.PNG](\/\/\/raw\/36b\/32\/z\/243ac.png)\n\nso @kichex asked about a doc explaining how to mod the game. Just for a little background, the code enabling the moddability is part of a larger project im working on. So the game is only partially moddable at this point.\n\nWhat you can change:\n\n\t\t\tPlayer Settings & Player SFX\n\n\t\t\tTileset GFX & Tile Definitions (does it kill on contact, is it collidable, etc.)\n\n\t\t\tGame Levels\n\n\t\t\tLevel Music\n\n\t\t\tLevel Backgrounds\n\nWhat you need:\n\n\t\t\tNotepad++ or another text editor - https:\/\/notepad-plus-plus.org\/\n\n\t\t\tTiled Map Editor - https:\/\/www.mapeditor.org\/\n\n\t\t\tWhatever you want to use for graphics\n\n\n\nAll the files are contained in the Faery Tales_Data\\StreamingAssets.\n\nLevels:\nPath: Faery Tales_Data\\StreamingAssets\n\n\t\t\tfaery1.json - level 1\n\t\t\tfaery2.json - level 2\n\t\t\tfaery3.json - level 3\n\t\t\tmenu.json - menu level\n\nthe game automatically loads menu.json at the menu screen. \n\nTilesets:\nPath:Faery Tales_Data\\StreamingAssets\\Tileset\n\nA tileset consists of two files. the PNG that contains the graphics, and the json that details what tiles do what. The tileset cannot have any more tiles than ff.png currently has. \n\nTilesets for a level are specified in the Map Properties in each level.\n\nif the file is called ff, the tile data file is called fftiles.json\n\nHere is sample content of the tile data:\n\n\n\t\t\t\"biome\" : \"spikes\",\n\t\t\t\"killOnContact\" : \"true\",\n\t\t\t\"collision\":\"grid\",\n\t\t\t\"tileIds\" : \"20\"\n\n\t\t\t\"biome\" : \"slopeUp\",\n\t\t\t\"collision\" : \"sprite\",\n\t\t\t\"atkBonus\" : \"0\",\n\t\t\t\"defBonus\" : \"60\",\n\t\t\t\"moveCost\" : \"2\",\n\t\t\t\"tileIds\" : \"4\",\n\t\t\t\"vertices\": \"0|0,16|0,16|16\"\n\nso here are two examples. One is a slope, the other is the spike tile. The tile ids go from top left to right, then down a row going left to right again. \n\nProperties that can be set:\n\n\t\t\tcollision : sprite, grid, none - sprite allows you set a collision mesh for the tile, if it isnt square. The game uses the vertices property when sprite is selected. grid is collision on a square, and none allows the character to pass through.\n\n\t\t\tkillOnContact: kills the player when they collide with the tile\n\n\t\t\tpassThrough : above \/ below - implementation of one way platforms - jumping is a little shaky on these, so this wasnt used.\n\n\t\t\tLadder : true \/ false - marks tile as a ladder tile. use w and s to move up and down the ladder. You can also jump off. \n\n\t\t\ttileIds : the list of tiles that apply to this tile type.\n\n\t\t\tvertices: 1|1, - first digit is X value, second digit is Y value. These are the points of the collision mesh if you use sprite for collision.\n\n\t\t\tNOTE: if the map wont load, 9 times out of 10, its because you have used a tile id twice in your tile definitions.\n\nBG-\n\nPath: Faery Tales_Data\\StreamingAssets\\BG\n\nBackgrounds are specified in the Map Properties in the level map. \n\nMusic-\n\nPath: Faery Tales_Data\\StreamingAssets\\Music\n\nMusic is specified in the Map Properties in the level map.\n\nSFX-\n\nPath: Faery Tales_Data\\StreamingAssets\\SFX\n\nSound effects are specified in playerConfig.json\n\nPlayer-\n\nPath: Faery Tales_Data\\StreamingAssets\\playerConfig.json\n\nMoveSpeed - max speed of player\n\nSounds- name of file in SFX folder to play for each event.\n\n\t\t\t\"gravityAdjust\": - an adjustment to the normal platforming controls to make jumping more floaty. Currently set to .45 out of 1.0\n\t\t\t\"accelTimeAirborne\": \"0.5\", - time to reach full horizontal speed while in air\n\t\t\t\"accelTimeGround\": \"0.3\", - time to reach full horizontal speed while on ground\n\t\t\t\"maxJumpHeight\": \"14\", - max height of a jump - this is affected by gravity adjust\n\t\t\t\"timeToJumpApex\": \"0.7\", - time to jumpApex - speed of jump - affected by gravity adjust.\n\n\nLevels-\nFaery Tales_Data\\StreamingAssets\\\n\nPlease use tiled, but you can also use notepad ++ to edit the levels.\n\nThe objects have different properties that let you alter their behavior.\n\nprefab: name of unity prefab to spawn.\n\nHere is a full list(some of these are from another project, but they should \"work\")\n\n\t\t\tFaeryTales Prefabs:\n\t\t\tDiver - diving drill\n\t\t\tBot\/Downward Bot - flying machine\n\t\t\tDwarf - ...\n\t\t\tswitchTile - tile that can be toggled on and off by a switch\n\t\t\tTurret - shooting turret\n\t\t\tnextLevel - level end marker\n\t\t\tspawnPoint - player Start\n\t\t\tspawnCam - spawns camera only\n\t\t\tmovingPlatform - platform that moves back and forth.\n\t\t\tkillzone - large prefab that kills player on contact. put these at the bottom of your level\n\t\t\tMedpack - health\n\t\t\tteleport - teleports player to another teleport\n\t\t\tteleportInvis - used as a target for the teleport, no graphic.\n\t\t\tSwitch - triggers switchTiles when shot or collided with.\n\n\t\t\tNonFaeryTales Prefabs:\n\t\t\tBouncyCannon 1 1- a box that bounces around and shoots.\n\t\t\tCrate- rigidbody crate that is destructible\n\t\t\tdestrucPlatform- destructable crate that stays in place.\n\t\t\tFlakPickup - Flak Cannon weapon\n\t\t\tRocketPickup - Rocket launcher weapon - does not shoot to the left correctly.\n\t\t\tjumppad - launches player in whatever direction its pointing.\n\t\t\tTank - an unfinished tank object that doesnt really work.\n\t\t\tswitchableSpawner - a spawner that can be toggled by a Switch.\n\t\t\tWandererTest - a box with a skull that follows a path.\n\nTheres a lot of properties specific to each object, but since this post is getting crazy long, im going to cut it off here for now. Have fun! Let me know if you guys have any more questions.\n\nTake a look at the existing json levels! You can see all the properties set for each object.\n\nhttps:\/\/ldjam.com\/events\/ludum-dare\/44\/faery-tales","comments":1,"comments-timestamp":"2019-05-01T22:18:32Z","created":"2019-05-01T21:21:00Z","files":[],"files-timestamp":0,"id":155792,"love":3,"love-timestamp":"2019-05-01T22:18:33Z","meta":[],"modified":"2019-05-02T00:40:56Z","name":"Faery Tales - Modding guide","node-timestamp":"2019-05-02T00:40:56Z","parent":146521,"parents":[1,5,9,139254,146521],"path":"\/events\/ludum-dare\/44\/faery-tales\/faery-tales-modding-guide","published":"2019-05-01T21:56:36Z","scope":"public","slug":"faery-tales-modding-guide","subsubtype":"","subtype":"","type":"post","version":468671},"node_metadata":{"n_key":"155792","n_urlkey":"348049","n_parent":"146521","n_path":"\/events\/ludum-dare\/44\/faery-tales\/faery-tales-modding-guide","n_slug":"faery-tales-modding-guide","n_type":"post","n_subtype":"","n_subsubtype":"","n_author":"146275","n_created":"1556745660","n_modified":"1556757656","n_version":"468671","n_status":"WAYBACK"},"source_url":"https:\/\/ldjam.com\/events\/ludum-dare\/44\/faery-tales\/faery-tales-modding-guide","text":"This is a modding guide for my game Faery Tales - https:\/\/ldjam.com\/events\/ludum-dare\/44\/faery-tales\n\n![Capture.PNG](\/\/\/raw\/36b\/32\/z\/243ac.png)\n\nso @kichex asked about a doc explaining how to mod the game. Just for a little background, the code enabling the moddability is part of a larger project im working on. So the game is only partially moddable at this point.\n\nWhat you can change:\n\n\t\t\tPlayer Settings & Player SFX\n\n\t\t\tTileset GFX & Tile Definitions (does it kill on contact, is it collidable, etc.)\n\n\t\t\tGame Levels\n\n\t\t\tLevel Music\n\n\t\t\tLevel Backgrounds\n\nWhat you need:\n\n\t\t\tNotepad++ or another text editor - https:\/\/notepad-plus-plus.org\/\n\n\t\t\tTiled Map Editor - https:\/\/www.mapeditor.org\/\n\n\t\t\tWhatever you want to use for graphics\n\n\n\nAll the files are contained in the Faery Tales_Data\\StreamingAssets.\n\nLevels:\nPath: Faery Tales_Data\\StreamingAssets\n\n\t\t\tfaery1.json - level 1\n\t\t\tfaery2.json - level 2\n\t\t\tfaery3.json - level 3\n\t\t\tmenu.json - menu level\n\nthe game automatically loads menu.json at the menu screen. \n\nTilesets:\nPath:Faery Tales_Data\\StreamingAssets\\Tileset\n\nA tileset consists of two files. the PNG that contains the graphics, and the json that details what tiles do what. The tileset cannot have any more tiles than ff.png currently has. \n\nTilesets for a level are specified in the Map Properties in each level.\n\nif the file is called ff, the tile data file is called fftiles.json\n\nHere is sample content of the tile data:\n\n\n\t\t\t\"biome\" : \"spikes\",\n\t\t\t\"killOnContact\" : \"true\",\n\t\t\t\"collision\":\"grid\",\n\t\t\t\"tileIds\" : \"20\"\n\n\t\t\t\"biome\" : \"slopeUp\",\n\t\t\t\"collision\" : \"sprite\",\n\t\t\t\"atkBonus\" : \"0\",\n\t\t\t\"defBonus\" : \"60\",\n\t\t\t\"moveCost\" : \"2\",\n\t\t\t\"tileIds\" : \"4\",\n\t\t\t\"vertices\": \"0|0,16|0,16|16\"\n\nso here are two examples. One is a slope, the other is the spike tile. The tile ids go from top left to right, then down a row going left to right again. \n\nProperties that can be set:\n\n\t\t\tcollision : sprite, grid, none - sprite allows you set a collision mesh for the tile, if it isnt square. The game uses the vertices property when sprite is selected. grid is collision on a square, and none allows the character to pass through.\n\n\t\t\tkillOnContact: kills the player when they collide with the tile\n\n\t\t\tpassThrough : above \/ below - implementation of one way platforms - jumping is a little shaky on these, so this wasnt used.\n\n\t\t\tLadder : true \/ false - marks tile as a ladder tile. use w and s to move up and down the ladder. You can also jump off. \n\n\t\t\ttileIds : the list of tiles that apply to this tile type.\n\n\t\t\tvertices: 1|1, - first digit is X value, second digit is Y value. These are the points of the collision mesh if you use sprite for collision.\n\n\t\t\tNOTE: if the map wont load, 9 times out of 10, its because you have used a tile id twice in your tile definitions.\n\nBG-\n\nPath: Faery Tales_Data\\StreamingAssets\\BG\n\nBackgrounds are specified in the Map Properties in the level map. \n\nMusic-\n\nPath: Faery Tales_Data\\StreamingAssets\\Music\n\nMusic is specified in the Map Properties in the level map.\n\nSFX-\n\nPath: Faery Tales_Data\\StreamingAssets\\SFX\n\nSound effects are specified in playerConfig.json\n\nPlayer-\n\nPath: Faery Tales_Data\\StreamingAssets\\playerConfig.json\n\nMoveSpeed - max speed of player\n\nSounds- name of file in SFX folder to play for each event.\n\n\t\t\t\"gravityAdjust\": - an adjustment to the normal platforming controls to make jumping more floaty. Currently set to .45 out of 1.0\n\t\t\t\"accelTimeAirborne\": \"0.5\", - time to reach full horizontal speed while in air\n\t\t\t\"accelTimeGround\": \"0.3\", - time to reach full horizontal speed while on ground\n\t\t\t\"maxJumpHeight\": \"14\", - max height of a jump - this is affected by gravity adjust\n\t\t\t\"timeToJumpApex\": \"0.7\", - time to jumpApex - speed of jump - affected by gravity adjust.\n\n\nLevels-\nFaery Tales_Data\\StreamingAssets\\\n\nPlease use tiled, but you can also use notepad ++ to edit the levels.\n\nThe objects have different properties that let you alter their behavior.\n\nprefab: name of unity prefab to spawn.\n\nHere is a full list(some of these are from another project, but they should \"work\")\n\n\t\t\tFaeryTales Prefabs:\n\t\t\tDiver - diving drill\n\t\t\tBot\/Downward Bot - flying machine\n\t\t\tDwarf - ...\n\t\t\tswitchTile - tile that can be toggled on and off by a switch\n\t\t\tTurret - shooting turret\n\t\t\tnextLevel - level end marker\n\t\t\tspawnPoint - player Start\n\t\t\tspawnCam - spawns camera only\n\t\t\tmovingPlatform - platform that moves back and forth.\n\t\t\tkillzone - large prefab that kills player on contact. put these at the bottom of your level\n\t\t\tMedpack - health\n\t\t\tteleport - teleports player to another teleport\n\t\t\tteleportInvis - used as a target for the teleport, no graphic.\n\t\t\tSwitch - triggers switchTiles when shot or collided with.\n\n\t\t\tNonFaeryTales Prefabs:\n\t\t\tBouncyCannon 1 1- a box that bounces around and shoots.\n\t\t\tCrate- rigidbody crate that is destructible\n\t\t\tdestrucPlatform- destructable crate that stays in place.\n\t\t\tFlakPickup - Flak Cannon weapon\n\t\t\tRocketPickup - Rocket launcher weapon - does not shoot to the left correctly.\n\t\t\tjumppad - launches player in whatever direction its pointing.\n\t\t\tTank - an unfinished tank object that doesnt really work.\n\t\t\tswitchableSpawner - a spawner that can be toggled by a Switch.\n\t\t\tWandererTest - a box with a skull that follows a path.\n\nTheres a lot of properties specific to each object, but since this post is getting crazy long, im going to cut it off here for now. Have fun! Let me know if you guys have any more questions.\n\nTake a look at the existing json levels! You can see all the properties set for each object.\n\nhttps:\/\/ldjam.com\/events\/ludum-dare\/44\/faery-tales","title":"Faery Tales - Modding guide","wayback_source":[]}