{"author_name":"BMacIntosh","cat":"LD #24","comments":[{"author_name":"t-recx","time":"August 26, 2012 3:06 am","epoch":1345968360,"text":"That&#8217;s looking pretty cool!","spam":"N"},{"author_name":"BMacIntosh","time":"August 26, 2012 10:17 am","epoch":1345994220,"text":"Hey, thanks :).  The genome has two parts.  The first has a number of &#8220;feature&#8221; genes, which include things like weapons and stat boosts.  Each of these genes can have a number of different values, which are subject to mutation individually.  Each genome contains a random assortment of these (10 is the usual number).  The second part has 5 &#8220;mandatory&#8221; genes, which include color and 4 parameters that control how the AI decides to move (aggressiveness, etc).  Each genome contains exactly one of each of these.","spam":"N"}],"epoch":1345959600,"likes":0,"metadata":{"p_key":"52815","p_author":"BMacIntosh","p_authorkey":"15030","p_urlkey":"88517","p_title":"Genetic Algorithms and Debugging","p_cat":"LD #24","p_event":"LD24","p_time":"1345959600","p_likes":"0","p_comments":"2","p_status":"UPD5","us_key":"15030","us_name":"BMacIntosh","us_username":"\/author\/bmacintosh\/","event_start":"1345766400","event_key":"12","event_name":"LD24"},"text":"<p>This is my first time participating in on of these competitions, and I&#8217;m greatly enjoying it so far. \u00a0I figured I&#8217;d write a blog post to summarize the first day here.<\/p>\n <p>My game has you fight waves of randomly-generated enemy &#8220;bots&#8221;. \u00a0When I say randomly-generated, I mean whole-hog random. \u00a0Colors, behaviors, weapons, stats &#8211; it can all change. \u00a0After the first set of enemies, I start using a genetic algorithm to combine these enemies, hopefully ramping up the difficulty and making some neat combinations.<\/p>\n <p>Genetic algorithms are really cool and they suck at the same time. \u00a0On the positive side, it&#8217;ll be easy to balance the game when the algorithm works right &#8211; if it keeps picking certain features over and over, I&#8217;ll nerf &#8217;em. \u00a0On the downside, it&#8217;s hard to tell if things aren&#8217;t working quite right. \u00a0I played a few generations and noticed that the game kept dropping weapons for some reason. \u00a0It would select out almost all weapons by the fourth generation. \u00a0I was pretty sure this was not, in fact, the optimal solution to the problem. \u00a0Turned out to be some misplaced curly braces (sheesh).<\/p>\n <p>So what&#8217;s still to do? \u00a0Sound and music, notably. A pause menu. I also think it would be pretty cool to have a system for exporting enemy genomes having friends fight them, or even having two bots fight each other.<\/p>\n <p>Here&#8217;s a screenshot!<br \/>\n <a href=\"http:\/\/www.ludumdare.com\/compo\/2012\/08\/26\/genetic-algorithms-and-debugging\/primeval\/\" rel=\"attachment wp-att-169013\"><img class=\"alignnone size-medium wp-image-169013\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2012\/08\/primeval-300x225.png\" alt=\"Screenshot\" width=\"300\" height=\"225\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/08\/primeval-300x225.png 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/08\/primeval-550x412.png 550w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/08\/primeval.png 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><\/p>","time":"August 26th, 2012 12:40 am","title":"Genetic Algorithms and Debugging"}