{"author_name":"Dax","cat":"LD #22","comments":[{"author_name":"Deza","time":"December 20, 2011 8:39 am","epoch":1324388340,"text":"Why not store them in three dimensional vectors? Seems much easier.","spam":"N"},{"author_name":"Dax","time":"December 20, 2011 9:21 am","epoch":1324390860,"text":"I prefer to have a graphical vision of the map, especially when we don&#8217;t have much time and I don&#8217;t have an external tool to visualise it.<br \/>\n Besides I can use my image map in XNA like a ressource in my content while text files are not managed.<br \/>\n And if I want something smaller then my pictures, I need to have binary files that I can&#8217;t edit easily.","spam":"N"}],"epoch":1324388220,"likes":0,"metadata":{"p_key":"60176","p_author":"Dax","p_authorkey":"7756","p_urlkey":"95929","p_title":"How Run Away maps work?","p_cat":"LD #22","p_event":"LD22","p_time":"1324388220","p_likes":"0","p_comments":"2","p_status":"UPD5","us_key":"7756","us_name":"Dax","us_username":"dax","event_start":"1323993600","event_key":"8","event_name":"LD22"},"text":"<p>Hello everyone!<\/p>\n <p>&nbsp;<\/p>\n <p>A little post to explain how I create levels in Run Away.<\/p>\n <p>All the system is based on pixels.<\/p>\n <p>First I got my set, here is my Hell set.<a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/hell-2\/\" rel=\"attachment wp-att-102125\"><img class=\"aligncenter size-full wp-image-102125\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Hell.png\" alt=\"\" width=\"140\" height=\"20\" \/><\/a><\/p>\n <p>Then I create on my paint editor a new image where 1 pixel is one tile in the game (classic).<\/p>\n <p>To choose which tile to use, I work on the Red color, Grass will be 0, Water will be 100 &#8230;<\/p>\n <p>Then I add foes, bonus, checkpoints\u00a0 and tuto points with Green color<\/p>\n <p>And to conclude, the Blue allows me to select a specific one. For exemple I can chose the foeI want to spawn.<\/p>\n <p>Here are my maps<\/p>\n <p>&nbsp;<\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/jump1\/\" rel=\"attachment wp-att-102120\"><img class=\"aligncenter size-full wp-image-102120\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Jump1.png\" alt=\"\" width=\"80\" height=\"30\" \/><\/a><\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/jump2\/\" rel=\"attachment wp-att-102121\"><img class=\"aligncenter size-full wp-image-102121\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Jump2.png\" alt=\"\" width=\"80\" height=\"60\" \/><\/a><\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/water1-2\/\" rel=\"attachment wp-att-102124\"><img class=\"aligncenter size-full wp-image-102124\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Water1.png\" alt=\"\" width=\"40\" height=\"80\" \/><\/a><\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/spike1\/\" rel=\"attachment wp-att-102123\"><img class=\"aligncenter size-full wp-image-102123\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Spike1.png\" alt=\"\" width=\"80\" height=\"60\" \/><\/a><\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/saws\/\" rel=\"attachment wp-att-102122\"><img class=\"aligncenter size-full wp-image-102122\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Saws.png\" alt=\"\" width=\"40\" height=\"90\" \/><\/a><\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2011\/12\/20\/how-run-away-maps-work\/boss-2\/\" rel=\"attachment wp-att-102119\"><img class=\"aligncenter size-full wp-image-102119\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2011\/12\/Boss.png\" alt=\"\" width=\"40\" height=\"30\" \/><\/a><\/p>\n <p>For the last one, that&#8217;s what we have in game:<\/p>\n <p><img class=\"aligncenter\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/compo2\/87574\/7756-shot1.png\" alt=\"\" width=\"418\" height=\"314\" \/><\/p>\n <p>In the game, the loading is really static, I could have added information on the Alpha of the first pixel to store data on the level for exemple the set (if it&#8217;s forest or lava) and the id (to know the order).<\/p>\n <p>My local values for each colors.<\/p>\n <blockquote><p>int GrassRed = 0;<br \/>\n int WaterRed = 100;<br \/>\n int PanelRed = 130;<br \/>\n int EndRed = 150;<br \/>\n int SpikeRed = 160;<br \/>\n int BossWallRed = 170;<br \/>\n int DefaultRed = 255;<\/p>\n <p>int SpawnGreen = 100;<br \/>\n int CheckPointGreen = 200;<br \/>\n int FoeGreen = 150;<br \/>\n int BonusGreen = 160;<br \/>\n int TextGreen = 170;<br \/>\n int ShadowGreen = 180;<\/p>\n <p>int FishBlue = 100;<br \/>\n int BirdBlue = 101;<br \/>\n int SawBlue = 102;<br \/>\n int HalfSawBlue = 103;<br \/>\n int HalfSawLeftBlue = 104;<br \/>\n int BirdNoCollideLeftBlue = 105;<br \/>\n int BirdNoCollideRightBlue = 106;<br \/>\n int SawNoCollideTopBlue = 107;<br \/>\n int BossBlue = 120;<br \/>\n int BossDamageBlue = 121;<\/p>\n <p>\/\/int SpawnSideRightBlue = 255;<br \/>\n int SpawnSideLeftBlue = 254;<br \/>\n int SpikeRightBlue = 254;<br \/>\n int SpikeBottomBlue = 253;<br \/>\n int SpikeLeftBlue = 252;<\/p><\/blockquote>\n <p>&nbsp;<\/p>\n <p>Thanks for reading, if you want some other little post on how my game works, please comment <img src=\"http:\/\/ludumdare.com\/compo\/wp-includes\/images\/smilies\/simple-smile.png\" alt=\":)\" class=\"wp-smiley\" style=\"height: 1em; max-height: 1em;\" \/><\/p>","time":"December 20th, 2011 8:37 am","title":"How Run Away maps work?"}