• Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Override - A Targeting Override Plugin

    Discussion in 'Archives' started by Apoc, May 30, 2010.

    1. Apoc

      Apoc Moderator Staff Member Moderator

      Joined:
      Jan 16, 2010
      Messages:
      2,790
      Likes Received:
      94
      Trophy Points:
      48
      New version in the first post. This one includes a few extra things that the internal HB targeting does by default.

      It now takes the faction lists into account, as well as avoid mobs.

      Elite targeting (based on the profile, if one is loaded) is also taken into account.

      Quest mobs do have extra weight now, but the weighting is 'global'. (It doesn't matter if you're in quest mode or not.) This may not actually add weight properly, as the quest API in honorbuddy is a bit obscure, so I'm not entire positive that I'm checking the correct IDs.

      It shouldn't crash HB anymore. (Excluding the check for the HB version.)
       
      highvoltz and okeofs like this.
    2. ski

      ski Well-Known Member

      Joined:
      Feb 12, 2010
      Messages:
      3,720
      Likes Received:
      48
      Trophy Points:
      48
      I'm cleaning up this thread because I don't want to see it locked, so if you see your post deleted, that's why.
       
    3. okeofs

      okeofs New Member

      Joined:
      Jan 15, 2010
      Messages:
      303
      Likes Received:
      1
      Trophy Points:
      0
      Can this be used in conjunction with questing to make sure characters don't run through packs of mobs?

      Edit: Typo
       
    4. okeofs

      okeofs New Member

      Joined:
      Jan 15, 2010
      Messages:
      303
      Likes Received:
      1
      Trophy Points:
      0
      Working great so far man...solid coding. Thanks!
       
    5. Forb1d

      Forb1d New Member

      Joined:
      Jan 15, 2010
      Messages:
      152
      Likes Received:
      3
      Trophy Points:
      0
      It depends on what you mean by that. If you mean while its attempting to path from one place to another, no. That is what blackspots are for. If you mean to stop it from targeting a mob that is on the opposite side of a pack, thus aggroing everything in between, yes.
       
    6. okeofs

      okeofs New Member

      Joined:
      Jan 15, 2010
      Messages:
      303
      Likes Received:
      1
      Trophy Points:
      0
      dope. thanks.
       
    7. Apoc

      Apoc Moderator Staff Member Moderator

      Joined:
      Jan 16, 2010
      Messages:
      2,790
      Likes Received:
      94
      Trophy Points:
      48
      Thank you! :)

      Yes, it can. It will force HB to use the target at the front of the pack, unless there is a 'safer' target elsewhere. (Eg; a mob with less *possible* adds if you pull it) Basically, it'll start at the front of the pack, and work it's way back. Instead of going straight to the back.
       
    8. okeofs

      okeofs New Member

      Joined:
      Jan 15, 2010
      Messages:
      303
      Likes Received:
      1
      Trophy Points:
      0
      Apoc you're the man. Many thanks.
       
    9. krakaskillz

      krakaskillz New Member

      Joined:
      Jan 15, 2010
      Messages:
      11
      Likes Received:
      0
      Trophy Points:
      0
      ok first off love this plugin. But i am getting crashes on it with different toons, and cc's everytime is the same error at the end of the log.
       

      Attached Files:

    10. Mupp

      Mupp New Member

      Joined:
      May 3, 2010
      Messages:
      613
      Likes Received:
      5
      Trophy Points:
      0
      Does this work in pvp aswell ?
       
    11. znuffie

      znuffie Banned

      Joined:
      Feb 23, 2010
      Messages:
      864
      Likes Received:
      30
      Trophy Points:
      28
      So, am I the only one that is getting this?

      Code:
      Exception from Override:
      System.Threading.ThreadAbortException: Thread was being aborted. ---> SmartAssembly.SmartExceptionsCore.UnhandledException: SmartExceptionsCore.UnhandledException @ 3077, offset:345 ---> SmartAssembly.SmartExceptionsCore.UnhandledException: SmartExceptionsCore.UnhandledException @ 3071, offset:43
         --- End of inner exception stack trace ---
         --- End of inner exception stack trace ---
         at Styx.Logic.Questing.PlayerQuest.get_IsCompleted()
         at Apoc.Plugins.TargetOverride.Override.<GetCurrentQuestMobEntries>b__b(PlayerQuest q) in c:\HB2\Plugins\Override.cs:line 146
         at System.Linq.Enumerable.WhereListIterator`1.MoveNext()
         at System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
         at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
         at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
         at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
         at Apoc.Plugins.TargetOverride.Override.GetCurrentQuestMobEntries() in c:\HB2\Plugins\Override.cs:line 146
         at Apoc.Plugins.TargetOverride.Override.CreateTargetList() in c:\HB2\Plugins\Override.cs:line 170
         at Apoc.Plugins.TargetOverride.Override.Targeting_OnTargetListUpdateFinished(Object context) in c:\HB2\Plugins\Override.cs:line 77
      
       
    12. Forb1d

      Forb1d New Member

      Joined:
      Jan 15, 2010
      Messages:
      152
      Likes Received:
      3
      Trophy Points:
      0
      Yup. Works fine for me, but i was his test dummy =P
       
    13. moujoohoo

      moujoohoo New Member

      Joined:
      Apr 29, 2010
      Messages:
      448
      Likes Received:
      1
      Trophy Points:
      0
      Great work.. keep on. Sweet plugin that works!
       
    14. Forb1d

      Forb1d New Member

      Joined:
      Jan 15, 2010
      Messages:
      152
      Likes Received:
      3
      Trophy Points:
      0
      Got another exception. In case you miss the MSN message =P

      "And heres an exception i just had thrown when i was running back, dead."

      Code:
      [COLOR=#000000][FONT=Segoe UI][SIZE=3]System.Threading.ThreadAbortException: Thread was being aborted. ---> SmartAssembly.SmartExceptionsCore.UnhandledException: SmartExceptionsCore.UnhandledException @ 3077, offset:345 ---> SmartAssembly.SmartExceptionsCore.UnhandledException: SmartExceptionsCore.UnhandledException @ 3071, offset:43
         --- End of inner exception stack trace ---
         --- End of inner exception stack trace ---
         at Styx.Logic.Questing.PlayerQuest.get_IsCompleted()
         at Apoc.Plugins.TargetOverride.Override.<GetCurrentQuestMobEntries>b__b(PlayerQuest q) in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 146
         at System.Linq.Enumerable.WhereListIterator`1.MoveNext()
         at System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
         at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
         at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
         at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
         at Apoc.Plugins.TargetOverride.Override.GetCurrentQuestMobEntries() in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 146
         at Apoc.Plugins.TargetOverride.Override.CreateTargetList() in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 170
         at Apoc.Plugins.TargetOverride.Override.Targeting_OnTargetListUpdateFinished(Object context) in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 77[/SIZE][/FONT][/COLOR]


      Also, i was in the middle of attacking a mob (neutral), when a hostile bear came up (and i think it attacked my pet, but im not sure). It then started killing the bear. Maybe you should weight the current target attacking above all others?
       
    15. Apoc

      Apoc Moderator Staff Member Moderator

      Joined:
      Jan 16, 2010
      Messages:
      2,790
      Likes Received:
      94
      Trophy Points:
      48
      Just to make it known, thread abort exceptions, I can't do anything about. Those are exceptions thrown in the HB core for whatever reason. (I'm just going to assume they use Lua a bit too liberally. And don't document which functions use it, so I can avoid them.) They are thrown in the injection helper code in HB, when things take a bit too long to execute. I'm handling them gracefully so it doesn't completely drop the bot when it fails.

      As for the target switching, find these lines:

      Code:
                              // If it's targeting me, we want it to have more priority.
                              if (TargetingMeOrPet(u))
                                  t.Weight += 300f;
      And change the '300f' to '500f', and it should try to stick to your current target more. (I must have typo'd when I wrote that weight.) However, don't go any higher, as sometimes you still do want to switch targets.
       
    16. Forb1d

      Forb1d New Member

      Joined:
      Jan 15, 2010
      Messages:
      152
      Likes Received:
      3
      Trophy Points:
      0
      Code:
      Exception from Override:
      System.NullReferenceException: Object reference not set to an instance of an object. ---> SmartAssembly.SmartExceptionsCore.UnhandledException: SmartExceptionsCore.UnhandledException @ 2739, offset:178
         --- End of inner exception stack trace ---
         at Styx.Logic.Questing.Quest.GetObjectives()
         at Apoc.Plugins.TargetOverride.Override.<GetCurrentQuestMobEntries>b__c(PlayerQuest q) in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 147
         at System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
         at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
         at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
         at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
         at Apoc.Plugins.TargetOverride.Override.GetCurrentQuestMobEntries() in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 146
         at Apoc.Plugins.TargetOverride.Override.CreateTargetList() in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 170
         at Apoc.Plugins.TargetOverride.Override.Targeting_OnTargetListUpdateFinished(Object context) in c:\Users\sychotix\Desktop\Backup Folder\HB2\Plugins\Override.cs:line 77
      
      
      was not watching the bot when this error happened, so i can't provide any further information. Sorry.
       
    17. Kredes

      Kredes New Member

      Joined:
      May 23, 2010
      Messages:
      92
      Likes Received:
      0
      Trophy Points:
      0
      Well is it stable? or does HB crash with it activated?

      i got this exception from Override

      Class: paladin
      CC: Mordd's
      Version of HB: 1.9.2.3
       
      Last edited: Jun 3, 2010
    18. Forb1d

      Forb1d New Member

      Joined:
      Jan 15, 2010
      Messages:
      152
      Likes Received:
      3
      Trophy Points:
      0
      He has already stated that he can't fix the "ThreadAbortException" because that is a problem on HB's side.

      Yes, this is fairly stable.
       
    19. TWKing

      TWKing New Member

      Joined:
      Apr 3, 2010
      Messages:
      89
      Likes Received:
      3
      Trophy Points:
      0
      First off, I'd like to say this is an awesome plugin. I've been running the latest questing beta and actually completing quests and not running thorugh hordes of mobs and creating an aggro train behind me. Sweet!
      Two things I did notice with this plugin though.
      1) It spends a lot of time killing the mobs around it and not focusing on the quests mobs/items. Is there a way to change the weighting so it makes a more direct line to the quest mobs instead of wandering around killing everything around it. Don't get me wrong, it eventually does get to the quest mobs, but only once it's killed everything else in the area.
      2) I ran into a situation where there was a dwarf nearby in Un'Goro Crater. I play a troll mage on a PVE server. As soon as the dwarf was in range, all my toon wanted to do was kill the dwarf. However I was not PVP flagged, so it kept spamming 'invalid target'. Is there a way to ignore player characters when not in PVP mode or BG?

      Thanks
       
    20. exfelon

      exfelon Active Member

      Joined:
      Jan 15, 2010
      Messages:
      1,372
      Likes Received:
      8
      Trophy Points:
      38
      Is there anything in relation to your pet being targetted/attacked? The toon targetting is pretty grand, but I couldn't really tell much about the pet. Say if I were out of combat but my pet is still in combat, to automatically assist your pet... but I also didn't pay that much attention. I just wanted to say thanks mostly for the great implementations apoc has given to the community.

      -update, I did read some of the code. i see some of the stuff i mentioned above.
       

    Share This Page