{"id":168,"date":"2009-04-27T13:38:57","date_gmt":"2009-04-27T18:38:57","guid":{"rendered":"http:\/\/www.vertigogaming.net\/blog\/?p=168"},"modified":"2009-04-27T13:38:57","modified_gmt":"2009-04-27T18:38:57","slug":"kablooey-shadows-color-filters","status":"publish","type":"post","link":"https:\/\/www.vertigogaming.net\/blog\/?p=168","title":{"rendered":"Kablooey! Shadows &#038; Color Filters"},"content":{"rendered":"<p>With every game I make I&#8217;m actively trying to experiment with different graphical features. With The Winter Solstice, it was the first attempt at using particles for both explosions and background images. With greenTech, it was applying visual overlays to graphically distort the display. And now there&#8217;s Kablooey, which I&#8217;m attempting both color filters and shadow effects.<br \/>\n<!--more--><br \/>\nI&#8217;ve had a lot of graphical assets left over from the now-canceled Helicopter Cacophony 3 game, but visually it wasn&#8217;t graphically pleasing to the eyes.<br \/>\n<!--break--><\/p>\n<p align=\"center\"><a href=\"http:\/\/www.vertigogaming.net\/hc3cap1.png\" rel=\"lightbox[ONR2]\" title=\"Eh.\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/hc3cap1.png\" border=\"0\" vspace=\"15\" width=\"412\" height=\"309\" \/><\/a><\/p>\n<p><!--break--><br \/>\nThe new game I&#8217;m working on will use these assets in a different way, but what I wanted to make sure of first was to somehow enhance the visuals and tie them in all together in a coherent visual display. I did this by using a color filter over the entire game, much like greenTech used the green display screen.<br \/>\n<!--break--><\/p>\n<p align=\"center\"><a href=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kthefilteroverlay.png\" rel=\"lightbox[ONR2]\" title=\"Real-time color filters easily tie the game world together without lengthy color corrections for each image\/sprite.\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kthefilteroverlay.png\" border=\"0\" vspace=\"15\" width=\"412\" height=\"309\" \/><\/a><\/p>\n<p><!--break--><br \/>\nThis isn&#8217;t just for the background though. Watch as the color filter is applied to the downtown section of the city:<br \/>\n<!--break--><\/p>\n<p align=\"center\"><a href=\"http:\/\/www.vertigogaming.net\/blog\/images\/Knonshadow1.png\" rel=\"lightbox[ONR2]\" title=\"Downtown, before any filters.\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/Knonshadow1.png\" border=\"0\" vspace=\"15\" width=\"412\" height=\"309\" \/><\/a><\/p>\n<p><!--break--><br \/>\n<!--break--><\/p>\n<p align=\"center\"><a href=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kprefinal.png\" rel=\"lightbox[ONR2]\" title=\"The color filter has been added. Bam.\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kprefinal.png\" border=\"0\" vspace=\"15\" width=\"412\" height=\"309\" \/><\/a><\/p>\n<p><!--break--><br \/>\nThe color tones are subtle, but it creates a pleasing look. Take a view of the blue glass building, how it&#8217;s a bit orange at the bottom but blue at the top. It suggests an illumination from the bottom grass to the blue sky. Neato.<br \/>\n<!--break--><br \/>\nStill, the image lacks any kind of separation&#8230;it looks more like cardboard cutouts than buildings. It was time to practice with shadows.<br \/>\n<!--break--><br \/>\nThere are two main kinds of shadows: prebaked, and dymanic. Because dynamic shadows can topple computers easily with resource requirements, it was an easy decision to go with prebaked. Prebaked is a term used when you just need some shadows in a location, but aren&#8217;t planning to move the lightsource or interact with it (in our case, the sun). Dynamic would create shadows in real time, changing wherever the light source is (imagine a swinging bulb in a dim room). The prebaked lighting works great in Kablooey because there&#8217;s no need for real time light changes or any background elements changing on the fly.<br \/>\n<!--break--><br \/>\nThere are two ways I&#8217;ve done shadows: literally prebaked using Photoshop and using Game Maker&#8217;s engine to provide shadows. Using Photoshop I created shadows and lights on buildings to create an illusion of maybe cloud covering overhead, or a wear and tear factor on a building. The same method was used in Sim City 4 with great results.<br \/>\n<!--break--><center><br \/>\n<img decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/exbakedlights.jpg\"><\/center><br \/>\n<!--break--><br \/>\nSo now that that&#8217;s done, it&#8217;s time to use Game Maker to supply the rest of the shadows. Some are actual real-time blendings of sprites, but most are simply blackened versions of sprites overlaid with an alpha of 0.2 or so. Check out the way the shadows bring some depth to an image without being immediately apparent:<br \/>\n<!--break--><center><br \/>\n<img decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/threetiershadows.png\"><\/center><br \/>\n<!--break--><br \/>\nNotice how the buildings become more separated and defined, and notice the palm tree giving out three unique shadows. Theoretically the shadows don&#8217;t make sense from a global light perspective, and that&#8217;s OK, as you can get away with a lot more in 2D than you could in 3D (in 3D these shadows wouldn&#8217;t make any sense and look almost ridiculous).<br \/>\n<!--break--><br \/>\nNow take a look at the final blending of shadows and lighting (note especially the scaffolding on the small blue tower with shadows, as it was barely noticeable at all in the non-shadowed version):<br \/>\n<!--break--><\/p>\n<p align=\"center\"><a href=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kfinal.png\" rel=\"lightbox[ONR2]\" title=\"There's going to be even more shadows at work in the final version, such as random cloud cover on the ground.\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.vertigogaming.net\/blog\/images\/Kfinal.png\" border=\"0\" vspace=\"15\" width=\"412\" height=\"309\" \/><\/a><\/p>\n<p><!--break--><br \/>\nIt&#8217;s been a blast (heh) working on Kablooey, and I look forward to unveiling the game for the first time with a teaser trailer sometime next month. Woo!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With every game I make I&#8217;m actively trying to experiment with different graphical features. With The Winter Solstice, it was the first attempt at using particles for both explosions and background images. With greenTech, it was applying visual overlays to graphically distort the display. And now there&#8217;s Kablooey, which I&#8217;m attempting both color filters and shadow effects.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":"","_links_to":"","_links_to_target":""},"categories":[1,23],"tags":[],"class_list":["post-168","post","type-post","status-publish","format-standard","hentry","category-game-maker","category-kablooey"],"_links":{"self":[{"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/168","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=168"}],"version-history":[{"count":9,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/168\/revisions"}],"predecessor-version":[{"id":177,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/168\/revisions\/177"}],"wp:attachment":[{"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=168"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=168"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.vertigogaming.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=168"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}