{"author_name":"VideoDog","cat":"LD #34","comments":[],"epoch":1450254480,"likes":4,"metadata":{"p_key":"9655","p_author":"VideoDog","p_authorkey":"58117","p_urlkey":"44877","p_title":"Don\u2019t Stop Drilling \u2013 Level Generation","p_cat":"LD #34","p_event":"LD34","p_time":"1450254480","p_likes":"4","p_comments":"0","p_status":"UPD5","us_key":"58117","us_name":"VideoDog","us_username":"videodog","event_start":"1449792000","event_key":"31","event_name":"LD34"},"text":"<p>&nbsp;<\/p>\n <p>Rick from VideoDog here.<\/p>\n <p style=\"text-align: left\">So it turns out when you put more than 12 hours into a game, the results are much better!<\/p>\n <p style=\"text-align: left\"><a href=\"http:\/\/ludumdare.com\/compo\/ludum-dare-34\/?action=preview&amp;uid=58117\" target=\"_blank\">Don&#8217;t Stop Drilling<\/a> is a huge improvement over our <a href=\"http:\/\/ludumdare.com\/compo\/ludum-dare-33\/?action=preview&amp;uid=58117\" target=\"_blank\">last game<\/a>, and I really think we all learned a lot! I feel\u00a0I speak for all the other VideoDogs when I say that we can&#8217;t wait for the next Ludum Dare! Now to give everyone something hopefully interesting to read, I&#8217;ll talk a little about our level generation in Unity.<\/p>\n <div id=\"attachment_526293\" style=\"width: 310px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/ludumdare.com\/compo\/ludum-dare-34\/?action=preview&amp;uid=58117\"><img class=\"wp-image-526293 size-medium\" src=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/DSDSS1-300x234.png\" alt=\"DSDSS1\" width=\"300\" height=\"234\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/DSDSS1-300x234.png 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/DSDSS1-550x429.png 550w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/DSDSS1.png 1134w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><p class=\"wp-caption-text\">&#8220;Please remember to drill at all times, lest you meet an unfortunate demise.&#8221;<\/p><\/div>\n <p>&nbsp;<\/p>\n <p>&nbsp;<\/p>\n <p>&nbsp;<\/p>\n <p>In Don&#8217;t Stop Drilling the generation of the board is determined based on various scripts we call &#8220;generators&#8221;. Original, I know. Now each generator is given a weighting to determine how often it <img class=\"wp-image-526296 alignleft\" src=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/BTSLV2-300x94.png\" alt=\"BTSLV2\" width=\"271\" height=\"85\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/BTSLV2-300x94.png 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/BTSLV2.png 306w\" sizes=\"(max-width: 271px) 100vw, 271px\" \/>is allowed to generate a layer.<\/p>\n <p>The RandomGenerator has the highest weighting, so I&#8217;ll focus on that\u00a0specifically.<\/p>\n <p>&nbsp;<\/p>\n <p>&nbsp;<\/p>\n <p><img class=\"wp-image-526301 alignleft\" src=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2015\/12\/BTSRNDM-265x300.png\" alt=\"BTSRNDM\" width=\"305\" height=\"346\" \/>As you can see here the &#8220;Weight&#8221; category has a value of .81. This means that RandomGenerator should generate about 81 out of 100 layers. But what will our friend the RandomGenerator place in a layer it generates? Well that is what sub weightings are for! Every item listed under the &#8220;Weightings&#8221; category contributes to the layer that RandomGenerator creates. So in this example 5 out of every 100 blocks generated should be Copper.<\/p>\n <p>I know most of you programmers out there must be thinking that this is nothing too crazy, but as a Artist\/Designer, this is pretty damn cool! I spent way too much time tweaking each level trying to get the balance right, and could probably spend a lot more. But alas, Ludum Dare is only 72 hours and every project must come to an end.<\/p>\n <p>&nbsp;<\/p>\n <p>&nbsp;<\/p>\n <p>&nbsp;<\/p>\n <p style=\"text-align: center\">________________________________________________<\/p>\n <p style=\"text-align: center\">Thanks for reading! I hope you found this short write up interesting!<\/p>\n <p style=\"text-align: center\">@VideoDogDev<\/p>\n <p style=\"text-align: center\">@Variant_3 &#8211; Rick (Art\/Design)<\/p>\n <p style=\"text-align: center\">@pmlamotte &#8211; Paul (Programming\/Design)<\/p>\n <p style=\"text-align: center\">@carnyth &#8211; Devin (Music\/Art\/Design)<\/p>\n <p style=\"text-align: center\">Special thanks to Brett and Mike who gave great feedback during development!<\/p>\n <p>&nbsp;<\/p>","time":"December 16th, 2015 3:28 am","title":"Don\u2019t Stop Drilling \u2013 Level Generation"}