{"id":621,"date":"2010-10-05T20:36:19","date_gmt":"2010-10-06T02:36:19","guid":{"rendered":"http:\/\/www.philhassey.com\/blog\/?p=621"},"modified":"2010-10-05T20:36:19","modified_gmt":"2010-10-06T02:36:19","slug":"dynamite-day-8-menus-and-stuff","status":"publish","type":"post","link":"https:\/\/www.philhassey.com\/blog\/2010\/10\/05\/dynamite-day-8-menus-and-stuff\/","title":{"rendered":"Dynamite: Day 8 &#8211; Menus and Stuff"},"content":{"rendered":"<p>So, today is off to an exciting start as I cut-n-paste some of my font code from Galcon and get it wrapped up how I want it for this project.  This took me about two hours, which is kind of a long time .. but .. I had to do a fair bit of reshuffling to get it working in my &#8220;new&#8221; framework.  Again, all the data is stored in JSON files, and things are a bit simpler in general.<\/p>\n<p><a href=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz021.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz021.png\" alt=\"DynamiteScreenSnapz021\" title=\"DynamiteScreenSnapz021\" width=\"512\" height=\"406\" class=\"aligncenter size-full wp-image-622\" srcset=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz021.png 512w, https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz021-300x237.png 300w\" sizes=\"auto, (max-width: 512px) 100vw, 512px\" \/><\/a><\/p>\n<p>Next up, some basic GUI stuff.  I&#8217;m going to use the GUI toolkit I made for Galcon, but I&#8217;ll be cleaning up the code a bit so that it plays nice with my new framework.  I&#8217;m not sure how I&#8217;m going to accomplish this yet.<\/p>\n<p>.. time passes ..<\/p>\n<p>I just hacked it in.  And commented out a bunch of stuff that didn&#8217;t compile right away, so as needed I&#8217;ll uncomment things and clean things up.  I gave some brief consideration to using some other GUI or making a new one, but then I realized I&#8217;ve used this GUI in Galcon and Galcon Fusion and I&#8217;ve got it working on a TON of platforms, so it&#8217;s got a lot of little stuff in it that works really well, and it&#8217;d be a bit of a waste to go and start something new.  I&#8217;ll just improve the code as I go, as needed, so to speak.  Here&#8217;s a screenshot to show I&#8217;m doing something:<\/p>\n<p><a href=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz022.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz022.png\" alt=\"DynamiteScreenSnapz022\" title=\"DynamiteScreenSnapz022\" width=\"512\" height=\"406\" class=\"aligncenter size-full wp-image-623\" srcset=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz022.png 512w, https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/10\/DynamiteScreenSnapz022-300x237.png 300w\" sizes=\"auto, (max-width: 512px) 100vw, 512px\" \/><\/a><\/p>\n<p>One thing about my basecode that is a bit weak is that it does contain a lot of C-strings instead of std::string .. I should probably work on upgrading my code to use all std::string a bit more than I do.<\/p>\n<p>I&#8217;ve now updated my game to save and load the current level on exit.  This way I can focus on adding gameplay to a single level that I&#8217;m editing.<\/p>\n<p>First off, I&#8217;m now loading full animation of the player and guard, because I want to get my player walking around, then the guard, then add explosions.  (Then there won&#8217;t be much left!)  I&#8217;m not sure if I&#8217;ll be using the player and guard images forever or not, but I figured for now I&#8217;ll at least get something loaded and I can always change them later if I have time (and money) to do so!<\/p>\n<p>I found and cut-n-pasted in a <a href=\"http:\/\/www.heyes-jones.com\/astar.html\">nice A-Star algorithm<\/a>, which I need for both the users and the guards to walk around properly.  It all seemed to work without much of a fuss, which is always nice.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>So, today is off to an exciting start as I cut-n-paste some of my font code from Galcon and get it wrapped up how I want it for this project. This took me about two hours, which is kind of a long time .. but .. I had to do a fair bit of reshuffling [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[116],"tags":[],"class_list":["post-621","post","type-post","status-publish","format-standard","hentry","category-dynamite"],"_links":{"self":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/621","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/comments?post=621"}],"version-history":[{"count":3,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/621\/revisions"}],"predecessor-version":[{"id":626,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/621\/revisions\/626"}],"wp:attachment":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/media?parent=621"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/categories?post=621"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/tags?post=621"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}