Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 rpg game help
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Fonzie




PostPosted: Sun Jan 23, 2005 3:41 pm   Post subject: rpg game help

this isn't exactly a question related to turing itself, but I don't know where else to put it. In my game I have put in intelligent ai. Basically, the enemy looks for where it can get bonuses on attacking. This doesn't happen very frequently. If the enemy can't get a bonus, it looks for the person with the weakest defence or magic defence, depending on the attack. A mage pretty much always has the lowest defence. this results in the enemies almost always targeting the mage. Is there any way I can fix this?
Sponsor
Sponsor
Sponsor
sponsor
Cervantes




PostPosted: Sun Jan 23, 2005 9:01 pm   Post subject: (No subject)

How about this:
Each enemy will calculate a value for each possible target, based on two things: a.) as you said, defense, and b.) if the character is attacking that enemy and doing lots of damage.
So, if the fighter has a defence of 8 and is attacking the monster and doing lots of damage, subtract 5 from the defence, to get a value of 3. The mage has a defence of 5 and is attacking the monster, but doing very little damage, since he's a weakling mage. Subtract 1. So, the fighter has a value of 3 and the mage a value of 4. Choose the lesser of the two. The enemy attacks the fighter.

This sounds like it's going to be a really great game. I can't wait to see the final version!
-Cervantes
Delos




PostPosted: Sun Jan 23, 2005 9:01 pm   Post subject: (No subject)

Add some variability to it. For example, the higher the 'Intelligence' (or other such property of the enemy) the more likely it is to actually implement this check.
Also, this helps stopping the AI from being omniscient...never a good thing.
Fonzie




PostPosted: Mon Jan 24, 2005 11:03 pm   Post subject: (No subject)

those are both great ideas. Unfortunately I didn't have time to finish them before the demo was due. That and the pictures during the fight actually look like vomit, all stretched or grainy. I'll be sure to consider them when I make the final version though. Thanks guys.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 4 Posts ]
Jump to:   


Style:  
Search: