Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Bots

Development::Bots Forum for bots.

Reply
 
Thread Tools Display Modes
  #1  
Old 04-05-2010, 06:00 AM
zydriaa
Fire Beetle
 
Join Date: Apr 2009
Location: canada
Posts: 2
Default Fix for bots not holding taunt if you get too close.

I found a fix for tanking bots not holding aggro when you get too close to the mob, with the fix you can leave smartaggro on and still let your tanks hold aggro if you get too close

here's the code...

In hate_list.cpp

find

Code:
if(cur->ent->IsClient()){
around line 283 and replace it with

Code:
if(cur->ent->IsClient() || cur->ent->IsBot()){
recompile, turn on smartaggro and your bots will now hold aggro...

I haven't tested it myself but if you want your pets to be able to tank for you like this too, you should be able to replace the line above with

Code:
if(cur->ent->IsClient() || cur->ent->IsBot() || cur->ent->IsPet()){
Reply With Quote
  #2  
Old 04-07-2010, 08:50 PM
gibroni
Hill Giant
 
Join Date: Jun 2009
Location: glendale
Posts: 193
Default

that is nice, but i think that over does it. now no matter what you do for damage you cant steal agro. i put this in for my pet, as i am a mage, but no matter what i cant take agro from pet. Seems there has to be a way to actually determine taunt amount? as that seems to have no effect at all. in fact taunt for pets just might be not right, as when i hit pet taunt it keeps saying taunting foe, master. it should say " no longer taunting target" when you hit taunt again.
Reply With Quote
  #3  
Old 04-08-2010, 11:12 AM
zydriaa
Fire Beetle
 
Join Date: Apr 2009
Location: canada
Posts: 2
Default

thats strange... I can still steal taunt from my bots... I still havent tested with pets but bots seem to be working as far as I can tell... I will look into pet classes in a little bit and see if it does the same thing for me
Reply With Quote
  #4  
Old 06-29-2010, 10:58 AM
Slaintemaith
Fire Beetle
 
Join Date: Apr 2010
Posts: 3
Default

Any word on this? We're going through a similar dilemma now on our server, and wonder if there's been a confirmed fix.
Reply With Quote
  #5  
Old 06-29-2010, 11:45 PM
Katinka
Fire Beetle
 
Join Date: Sep 2006
Posts: 11
Default

Quote:
Originally Posted by Slaintemaith View Post
Any word on this? We're going through a similar dilemma now on our server, and wonder if there's been a confirmed fix.
Its simple, Cong needs to put in a Taunt/no tuant toggle for the bots
Reply With Quote
  #6  
Old 12-01-2010, 03:32 PM
Brewhaus
Sarnak
 
Join Date: Aug 2010
Posts: 38
Default

Does this need to be put in the code submissions forum to get put in the next release?
Reply With Quote
  #7  
Old 12-01-2010, 04:30 PM
Caryatis
Dragon
 
Join Date: May 2009
Location: Milky Way
Posts: 541
Default

I dont think this is an elegant enough solution to be put into the main source. I haven't tested it but it seems to not be the best way to accomplish it.
Reply With Quote
  #8  
Old 12-01-2010, 07:46 PM
pfyon's Avatar
pfyon
Discordant
 
Join Date: Mar 2009
Location: Ottawa
Posts: 495
Default

I'm not sure what better a solution there is. As I understand, it's just treating bots and pets the same way clients are for hate. I haven't tested it, though.
Reply With Quote
  #9  
Old 12-01-2010, 11:39 PM
Brewhaus
Sarnak
 
Join Date: Aug 2010
Posts: 38
Default

Well, the pet part shouldn't be put into it I don't think. Pretty sure pets didn't keep aggro in live.
Reply With Quote
  #10  
Old 12-02-2010, 06:07 PM
steve
Discordant
 
Join Date: Jan 2002
Posts: 305
Default

Quote:
Originally Posted by Brewhaus View Post
Well, the pet part shouldn't be put into it I don't think. Pretty sure pets didn't keep aggro in live.
They didn't and still don't.
Reply With Quote
  #11  
Old 04-15-2011, 02:53 PM
bad_captain
Developer
 
Join Date: Feb 2009
Location: Cincinnati, OH
Posts: 512
Default

I'm playing around with this a little. I started up a monk that I can't really play because mobs attack me instead of my warrior bot.

I replaced the code mentioned first, which is comething like
Code:
if(cur->ent->IsClient()) {
}
to
Code:
if(!cur->ent->IsPet()) {
}
as I don't believe the IsBot() check will compile for non-bot releases.. I have thought about changing this to
Code:
if(!cur->ent->IsPet() && !cur->ent->IsNPC()) {
}
but I wasn't sure of the consequences. This would impact npc attacking other npcs, so that they would attack PCs or Bots rather than continuing to attack the NPC which I believe would be more livelike. One situation that I havn't considered too much is npc or pc charming.. I'd have to think about it, or if anyone has any ideas, I would appreciate it. I would not change this myself without the approval of someone a little more familiar with aggro code, etc.

But, in the little bit of testing I did last night.. I went in to attack, and the mob attacked me back. My bots attacked right after me, but the mob continued to attack me until the warrior had a successful taunt, and then he kept the aggro until the mob was dead. This seems to be the behavior I would expect, and I will continue to test this out so maybe it can make it in. I will at least be running it on my private server.
Reply With Quote
  #12  
Old 04-15-2011, 05:03 PM
lerxst2112
Demi-God
 
Join Date: Aug 2010
Posts: 1,743
Default

You could just #ifdef the bot part, although it makes the code kinda fugly.

Code:
if(cur->ent->IsClient()
#ifdef BOTS
|| cur->ent->IsBot()
#endif
)
{
...
}
A prettier alternative is something like this...

Code:
bool ShouldAttack = cur->ent->IsClient();
#ifdef BOTS
ShouldAttack = (ShouldAttack || cur->ent->IsBot());
#endif
if(ShouldAttack)
{
...
}
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 07:22 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3