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

Development::Bots Forum for bots.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #12  
Old 07-14-2011, 04:54 PM
lerxst2112
Demi-God
 
Join Date: Aug 2010
Posts: 1,742
Default

Quote:
Originally Posted by bad_captain View Post
When #Showstats is called, it is on a Mob*, not Bot*, which I believe causes it to call the Mob version of GetAC(). That version adds in item and spell AC, which has already been included in the AC value.
It sounds like you may not know how virtual functions work. Virtual means that no matter what type of pointer you have in a class hierarchy, calling a virtual function will call the most derived function available that matches the proper signature.

The GetAC function in the bot class doesn't match the signature of any virtual function in the base class, so it is never called as a virtual function. If the signature was corrected to match the base it would work just fine.
Reply With Quote
 


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 04:18 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 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3