{"author_name":"lucasvb","cat":"LD #21","comments":[],"epoch":1313856780,"likes":2,"metadata":{"p_key":"64319","p_author":"lucasvb","p_authorkey":"5192","p_urlkey":"100106","p_title":"Some progress!","p_cat":"LD #21","p_event":"LD21","p_time":"1313856780","p_likes":"2","p_comments":"0","p_status":"UPD5","us_key":"5192","us_name":"lucasvb","us_username":"lucasvb","event_start":"1313712000","event_key":"7","event_name":"LD21"},"text":"<p>In the wise words of Ash Williams from Army \u00a0of Darkness: &#8220;Oh nooo! I&#8217;ve slept too much!&#8221;<\/p>\n <p>But having your batteries charged makes a big \u00a0difference. I can already think clearer than before. Here&#8217;s a simple screenshot:<\/p>\n <p>&nbsp;<\/p>\n <p><a href=\"http:\/\/i.imgur.com\/kZ6MX.png\"><img class=\"alignnone\" src=\"http:\/\/i.imgur.com\/kZ6MX.png\" alt=\"\" width=\"531\" height=\"438\" \/><\/a><\/p>\n <p>What I&#8217;ve got so far:<\/p>\n <ol>\n <li>Moving between rooms engine.<\/li>\n <li>Crappy collision detection (improving that now)<\/li>\n <li>Layers! You can walk behind stuff!<\/li>\n <li>Walking and running, with animation. Looks pretty good in game. Running animation is just a sped-up walking animation right now.<\/li>\n <li>The character also blinks. Not a huge thing, but these details are the things that bring life to characters.<\/li>\n <\/ol>\n <p>Now to fix the collision and make locked doors and interactive objects.<\/p>\n <p>&nbsp;<\/p>\n <p>Since I don&#8217;t have a lot of time to code anything complex, everything is being hardcoded and precomputed. Here&#8217;s what the collision map looks like:<\/p>\n <p><img class=\"alignnone\" src=\"http:\/\/i.imgur.com\/BHV02.png\" alt=\"\" width=\"500\" height=\"300\" \/><\/p>\n <p>Green is ground. If a color has red=255, it means it&#8217;s \u00a0a doorway or a &#8220;transitional object&#8221;. Run into it, and the game will pick up the blue component of the color as an ID.<\/p>\n <p>This ID is used to load another room with a fade-out fade-in transition. Simple stuff.<\/p>\n <p>The ID is not unique for the game, but for the room. \u00a0This means that, in a single room, I can have &#8220;doorways&#8221; \u00a0to up to 256 other rooms. Ain&#8217;t that cute?<\/p>\n <p>(Currently, I&#8217;m just loading the same room over and over. It&#8217;s actually quite creepy. I think I&#8217;m gonna use this!)<\/p>\n <p>When I change a rooms, I have a state object that gives me the previous room name. I can use this to place the character in the proper location in the new room, as well as run state-specific events later.<\/p>\n <p>&nbsp;<\/p>\n <p>All right, enough talking. Must write more code!<\/p>","time":"August 20th, 2011 11:13 am","title":"Some progress!"}