Newsgroups: comp.ai.genetic
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news2.near.net!howland.reston.ans.net!news.sprintlink.net!news.indirect.com!s68.phxslip3.indirect.com!enigma
From: enigma@indirect.com (Andy Sherwood)
Subject: Re: GA For Starfleet Battles? or How To Kill Each Other (Efficiently)
Message-ID: <enigma.3.00140FF4@indirect.com>
Sender: usenet@indirect.com (System Operator)
Organization: Nothing, Inc.
Date: Thu, 3 Nov 1994 03:03:36 GMT
References: <enigma.2.00166BC7@indirect.com> <3988eb$q0j@calvin.st-and.ac.uk>
X-Newsreader: Trumpet for Windows [Version 1.0 Rev A]
Lines: 80

In article <3988eb$q0j@calvin.st-and.ac.uk> ccjm@st-andrews.ac.uk (-Colin-) writes:
>From: ccjm@st-andrews.ac.uk (-Colin-)
>Subject: Re: GA For Starfleet Battles? or How To Kill Each Other (Efficiently)
>Date: 2 Nov 1994 14:41:15 GMT

>> paraphrased problem: getting fleets of starships of varying types to 
>> kill each other effectively.

>OK, this looks a little optimistic, if you are really intending to 
>implement this. How about starting simply and building up.

>What you need, if you want to do this genetically, is a large 
>population of similar units, with randomly pre-generated behaviour 
>patterns. You need some way to rate their progress (i.e. how many units 
>they kill, how long they live). Simplistically you could just start 
>with fighters vs fighters (or whatever) and say that any fighter that 
>kills another has it's gene code passed on to the next generation (i.e. 
>Starfleet notes that these tactics work well and tells future pilots to 
>use them).

Precisely my thinking..  I'm going to start building the enviorment they fight 
in tommorow, and will start by throwing in two fighters and letting them fly 
around a bit, similiar to a program called "Spacewar" written umpteen years 
ago for the PC/XT..  

>Now you decide how you want to breed them. You could just keep 
>passing on the genes, but this won't make your *fighters* better, only  
>your fleets. So you randomly mutate the genes, or breed different 
>successful fighters in whatver way you want.

>At the next level of complexity (for this specific problem) you could 
>rate fighters in different ways (offensive and defensive ratings) and 
>breed high offence patterns with high defence patterns.

I thought about this as well..  I plan on having all agents have on common 
gene, "Fight or flight".  It will be a percentage of damage taken, at which 
point the ship will stop fighting and run away, either seeking the shelter of 
a larger ship to repair it, or to repair itself.  For some of the larger ships 
an additional "Call for reinforcements" percentage will be instilled.  I think 
I'm going to base this gene more on total hits in a given time rather than a 
certain percentage however.  That way if a ship is getting pummeled, it can 
request reinforcements, and any fighter just milling around looking for 
trouble will get the call.


>The thing to remember is that you need as large a population as 
>possible so that you can get a meaningful measure of success. Extending 
>this problem by including larger (and thus more survivable) units makes 
>it more complex in that all your units need different tactics and 
>rating against all other units *and* that you will have a lower 
>turnover of generations and smaller gene pool. 

>Perhaps you could stage it in "battles". Let them fight for a set 
>time, collect all the stats from the battle and build whole new ships. 
>If your big ships all do equivelantly well (which is likely) then breed 
>them randomly, or just mutate.


Exactly.  There will be battle after battle, each battle will consist of a new 
generation of ships with a new set of genes derived from the "fittest" ships 
of the pervious generation.  Plus, a mutation factor that is user selectable, 
i.e. odds of mutation are 1 to 10,000 etc..  I believe a typical mutation 
chance of mutation for the size gene pool I have will be about 1 in 2000.

>As to using other forms of AI (on the capital ships), go for it. 
>Although if you are using anything complex then you'll likely have to 
>improve through mutation rather than breeding (which is as likely to 
>give morons as genii).

>Actually, this does sound interesting. If you're seriously interested in 
>writing something like this then drop me some mail; I know a bit of 
>C+whatever and some other junk. I even play SFB, if that's what you're 
>using for the interactions.


I am serious about writing it.  VERY serious.. I've already got all the code 
done for the generation of the ships, i.e. graphics, ship defination, weapon 
definition, etc.  Now its time to get into the juicy stuff..


