{"author_name":"nesis","cat":"LD #30","comments":[],"epoch":1409508660,"likes":1,"metadata":{"p_key":"26332","p_author":"nesis","p_authorkey":"2726","p_urlkey":"61759","p_title":"Post-Compo Design Iteration","p_cat":"LD #30","p_event":"LD30","p_time":"1409508660","p_likes":"1","p_comments":"0","p_status":"UPD5","us_key":"2726","us_name":"nesis","us_username":"nesis","event_start":"1408665600","event_key":"24","event_name":"LD30"},"text":"<p>This post is\u00a0about developing my game Matters of Perspective for after Ludum Dare. In it, I&#8217;ll talk about\u00a0a quick level editor I made to save tons of time, and how I&#8217;m reworking\u00a02D physics for better player experience.<\/p>\n <p><strong>If you haven&#8217;t seen my game <a href=\"http:\/\/www.ludumdare.com\/compo\/ludum-dare-30\/?action=preview&amp;uid=2726\" target=\"_blank\">Matters of Perspective<\/a>, a game about changing perspective from sidescroll to perspective to explore eerie rooms, please do <a href=\"http:\/\/www.ludumdare.com\/compo\/ludum-dare-30\/?action=preview&amp;uid=2726\" target=\"_blank\">check it out<\/a> and let me know what you think!<\/strong><\/p>\n <p>Even if you don&#8217;t rate it, any\u00a0feedback in the comments is very valuable to me!<\/p>\n <p>Here&#8217;s a quick gif showing a change in perspective:<\/p>\n <p><img class=\"alignnone\" src=\"https:\/\/dl.dropboxusercontent.com\/u\/28724945\/LD30\/test2_512_retitled.gif\" alt=\"\" width=\"512\" height=\"384\" \/><\/p>\n <p><strong>Level Editing<\/strong><\/p>\n <p>I&#8217;ve spent some time figuring out the fastest way to iterate level designs. A fast iteration time means a better level design is approached much sooner. During\u00a0Ludum Dare, I manually placed a ton of cubes (around\u00a01500-2000!) in all the levels. Iterating those designs was painstakingly slow, and took roughly the last 16-20\u00a0hours of my time. After trying a few methods, I&#8217;ve settled on writing my own simple editor for level geometry.<\/p>\n <p>With this new level editor,\u00a0I threw together a large level in about 30 mins, iterating the design\u00a0extremely easily.\u00a0Iterating a level&#8217;s design\u00a0includes improving navigability, layout, wall heights, directing\u00a0the player&#8217;s\u00a0view, hiding an easter egg, etc. Here&#8217;s an example of what I threw together:<\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_1.png\"><img class=\"alignnone size-medium wp-image-390446\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_1-300x225.png\" alt=\"physicsTesting1_1\" width=\"300\" height=\"225\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_1-300x225.png 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_1-550x412.png 550w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_1.png 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_2.png\"><img class=\"alignnone size-medium wp-image-390447\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_2-300x225.png\" alt=\"physicsTesting1_2\" width=\"300\" height=\"225\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_2-300x225.png 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_2-550x412.png 550w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2014\/08\/physicsTesting1_2.png 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n <p>&nbsp;<\/p>\n <p>It looks like creating good levels is going to be\u00a0a heck of a lot easier than I thought \ud83d\ude00<\/p>\n <p><strong>Reworking 2D Physics<\/strong><\/p>\n <p>As you could expect, the physics in the compo version of the game were hackishly put together to have something playable, rather than something that was necessarily the best experience for the player. 2D sidescrolling was\u00a0achieved with a\u00a0SphereCollider, doing various 2D-style checks to make it work like a 2D character controller. The biggest\u00a0problem\u00a0with this approach\u00a0is ensuring the sphere can pass through gaps as desired. At least once during play, players usually\u00a0find\u00a0the sphere\u00a0catching on\u00a0geometry that <em>should<\/em> be\u00a0the foreground or\u00a0background.<\/p>\n <p>This issue can be fixed by instead using the 2D physics system in Unity3D. However, this brings up another issue. The sidescrolling I want to do is all done on a horizontal plane, with gravity going down along the Z-axis. The sidescrolling built in to Unity3D&#8217;s 2D physics is all done on a\u00a0<em>vertical<\/em> plane, with gravity going down along the Y-axis.\u00a0To make matters more tricky, 3D colliders (like ones I could use to collide with a\u00a0Sphere) don&#8217;t collide\u00a0with 2D colliders at all, ever. In Unity, 2D and 3D\u00a0are two totally\u00a0separate physics\u00a0systems.<\/p>\n <p>To address this issue, I&#8217;ve used\u00a0procedural generation. In the editor,\u00a03D geometry and colliders are\u00a0created (a rectangular prism with changeable size), then 2D\u00a0colliders are generated during play. Depending on the player&#8217;s height, different 2D colliders are enabled and disabled, which ensures players won&#8217;t catch on &#8220;invisible&#8221; geometry as they run around in sidescroller mode.<\/p>","time":"August 31st, 2014 1:11 pm","title":"Post-Compo Design Iteration"}