[TIB] Re: AI


[Prev][Next][Index][Thread]

[TIB] Re: AI



Well, I have to agree, that randoms seem to be the only way to do AI, in my trek game, I made random a huge part of the enemy movement…ill be posting it on my half of the raptorware site http://raptorware.4ubutcher.com (currently offline for webserver repair) very soon. Along with the source, so check it out for what I know about AI J

 

Jeremy Butcher Aka RaptorKirk

 

-----Original Message-----
From: ti-basic-bounce@lists.ticalc.org [mailto:ti-basic-bounce@lists.ticalc.org] On Behalf Of RaptorDrew
Sent: Saturday, June 14, 2003 9:49 PM
To: ti-basic@lists.ticalc.org
Subject: [TIB] Re: AI

 

Yea, I did this in my "Final Fantasy" game... I am just interested in trying something more difficult, and also it could carry over to my Palm programming (attempting to write C on my Visor)

 

RaptorDrew

----- Original Message -----

From: MyOwnLittlWorld@aol.com

To: ti-basic@lists.ticalc.org

Sent: Saturday, June 14, 2003 9:45 PM

Subject: [TIB] Re: AI

 

well, the easiest way is to just use good old random #s...  perhaps you could weight the different actions differently if you wanted relative percents...

The sensible way:
rand -> A
If A>.9
Disp "action 1! - A 10% chance!"
If A>.7 and A<=.9
Disp "Action 2! - A 20% chace!"

or, the fly by night way...
If rand>(1/3)
Then
Disp "action 1! A 33% chace!"
Else
If rand>.5
Then
Disp "action 2!  A 33% chance!"
Else
Disp "action 3!  A 33% chance!"
End
End

(the second way's my favorite for no good reason at all.)
Nick


References: