What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Bestiary Implementation

so if I press v I can catch manuel but it does not work automatically or is there a trick?
 
so if I press v I can catch manuel but it does not work automatically or is there a trick?

Did you actually read what he said the plugin does? It only catches either the spirit beasts or 2 affix beasts. They aren't that common, are you sure you've even encountered one that meets the requirements?
 
install all this and you will see that you can catch manuel beasts
 
Work in progress.
Tested with both high tier nets and necromancy nets in inventory with the "Switch nets" and "Use Necromancy nets" setting turned on. Working good with my setup.

If you encounter any bugs please let me know what settings you use.
 

Attachments

Work in progress.
Tested with both high tier nets and necromancy nets in inventory with the "Switch nets" and "Use Necromancy nets" setting turned on. Working good with my setup.

If you encounter any bugs please let me know what settings you use.

Good Job, so far works great.
 
Updated with some small changes and a setting for maximum health.
The setting for yellow/red is actually 1 or >1 bestiary affixes. I will see if I can figure out a way to distinguish between them in a better way.

I would also like to add a timeout/blacklist for beasts that can't be captured but the API says they can. (Will currently result in a loop, don't seem to happen often though).
 

Attachments

Thanks, its doing great - how ever, im not sure if the sliders for when to catch the mobs is working correct? as i understand the closer the left i put it - less life the mob shou+ld have right?

Im playing SR/RF so im not exactly blowing the mobs up - so it should have time to catch them when i put it to something that looks like 30%, but it alwaysd end up killing them before using the normal net - then it uses necro net instead :D
 
Thanks, its doing great - how ever, im not sure if the sliders for when to catch the mobs is working correct? as i understand the closer the left i put it - less life the mob shou+ld have right?

Im playing SR/RF so im not exactly blowing the mobs up - so it should have time to catch them when i put it to something that looks like 30%, but it alwaysd end up killing them before using the normal net - then it uses necro net instead :D

You might be right. I've only tested with "Red" beasts and the logic may be a bit weak concerning the others. I'll have a look :)
 
Made some improvements which is supposed to be better at HP thresholds. Not tested extensively.
Also possible to adjust tick interval to update more often, or less often.
 

Attachments

so I found a major bug when capturing Beast, If the monster is imprisoned in a powerful essence "example being a beast that you want to capture" you are spammed with this error message.

Code:
[CaptureBeastTask] Throwing net at Bestiary monster: Chrome-touched Chimeral
[ThrowNetAt] Now attempting to highlight 4087 [Metadata/Monsters/GemMonster/IguanaChrometouched].
[ThrowNetAt] The target could not be highlighted.
[CaptureBeastTask] Attempting to capture Bestiary monster: Chrome-touched Chimeral
[CaptureBeastTask] Throwing net at Bestiary monster: Chrome-touched Chimeral
[ThrowNetAt] Now attempting to highlight 4087 [Metadata/Monsters/GemMonster/IguanaChrometouched].
[ThrowNetAt] The target could not be highlighted.
[InjectKeyEvent] 112 ms sleep for 86.
[CaptureBeastTask] Attempting to capture Bestiary monster: Chrome-touched Chimeral
[CaptureBeastTask] Throwing net at Bestiary monster: Chrome-touched Chimeral
[ThrowNetAt] Now attempting to highlight 4087 [Metadata/Monsters/GemMonster/IguanaChrometouched].
[ThrowNetAt] The target could not be highlighted.
[InjectKeyEvent] 94 ms sleep for 86.
[CaptureBeastTask] Attempting to capture Bestiary monster: Chrome-touched Chimeral
[CaptureBeastTask] Throwing net at Bestiary monster: Chrome-touched Chimeral
[ThrowNetAt] Now attempting to highlight 4087 [Metadata/Monsters/GemMonster/IguanaChrometouched].
[ThrowNetAt] The target could not be highlighted.
[InjectKeyEvent] 113 ms sleep for 86.
 

Attachments

  • Untitled.webp
    Untitled.webp
    100.8 KB · Views: 46
The Essence imprisoned beast is indeed one edge case that does have to be handled correctly.

For alive beast processing, the reason the current code bugs out is because IsActive is not used to check if the current monster is "active". IsValid only does a check to make sure the object's BaseAddress is not 0, so it's not useful for most normal code. Storing the monster's ID and looking up the object on next frame is more desired, but if the current object caching works it should be ok, but not really advised most of the time because of how memory works.

"IsActive" checks the following in the API:
Code:
Reaction == Reaction.Enemy && !IsDead && IsTargetable && !Invincible && !IsHidden;

Certain monsters that "emerge" from the ground, from a statue like state, or from the air actually have two metadata objects for the monster itself. For example,
[81] Gravel Eater | Metadata/Monsters/SandSpitterEmerge/SandSpitterEmergeStandard
has a parent pointer that points to this entry
[68] Gravel Eater | Metadata/Monsters/SandSpitters/SandSpitter1

The Bestiary API does the net check like the game does and handles the lookup correctly for the parent type, but this brings about the core issue at hand.

If you were only check IsActive, you'd miss processing the submerged monster because it's not active in that state. It only becomes active once you trigger it by proximity, and then the metadata of the monster that appears is different.

So simply checking IsActive when really close to the monster will avoid a stuck issue, but if Monolith logic isnt allowed to run, then it'll always be stuck there until it times out.

You'll have to borrow some code from Monoliths to process them correctly before trying to net them, but I'll look at adding support to the Monster API for something like an IsImprisoned check that will check against monolith data so you the issue can be avoided more easily. Up until now, there's been no use in knowing if a monster was imprisoned since you either were going to hit the monolith, or the monsters trapped were already being ignored since they were not active.

Later on, we can also do some minor Bestiary updates to the Monoliths plugin, as before the only thing that really could affect them was a Tormented Spirit, so this is just an example of how the game dynamics can change with new league mechanics.
 
Thanks, I'll have a look at it! I never ran into that myself as my max HP percentage setting is < 100 %.
 
The next Beta will have some Monolith related API updates as well since I noticed some stuff broke when checking it:
* Monolith.ChildNetworkObjectId added.
* Monolith.ChildNetworkObject updated as it was broken for 3.2+.
* Monster.IsImprisoned added to know when a monster is trapped by an Essence Monolith.
* LokiPoe.ObjectManager.GetObjectsByPosition added, as the only way to link a Monolith and Monster now is by exact position.
 
okay two things, how to target just yellow or even just red icon beasts ? my bot tries to and even captures normal beasts, no matter the threshold percentage.. So there goes all my necro net on trash mobs..
And sometimes it seems that when beast is captured, while waiting for animation of Einhar to appear and take it away bot waits next to the monster, in log it says [TrackMobTask] Alive monster is nearby, this is our 1/20 attempt to kill it.

Just wanted to report this, thanks and keep up the good work
 
okay two things, how to target just yellow or even just red icon beasts ? my bot tries to and even captures normal beasts, no matter the threshold percentage.. So there goes all my necro net on trash mobs..
And sometimes it seems that when beast is captured, while waiting for animation of Einhar to appear and take it away bot waits next to the monster, in log it says [TrackMobTask] Alive monster is nearby, this is our 1/20 attempt to kill it.

Just wanted to report this, thanks and keep up the good work

It shouldn't capture normal monsters unless they have not been captured before and you have checked "Capture new", or if it's a named monster you have in the list.
However if you have several new monsters the corpses might stay marked as "new" for a short time after the first is captured?

About the waiting, that's probably your combat routine trying to kill the imprisoned beast. You could fix that like this:
In OldRoutine (assume you are using that or similar) find the CombatTargetingOnInclusionCalcuation method and add this:

if (m.HasBestiaryCapturedAura || m.HasBestiaryDisappearingAura) { Log.Warn("Has Bestiary 'Inactive' Aura"); return false; }
 
in log it says [TrackMobTask] Alive monster is nearby, this is our 1/20 attempt to kill it.

That's coming from TrackMobLogic in our code. An untested temp fix is to change "TrackMobLogic.cs"

Old Line 62:
if (monsterObj == null || monsterObj.IsDead)

New Line 62:
if (monsterObj == null || monsterObj.IsDead || (Loki.Game.LokiPoe.InstanceInfo.Bestiary.IsActive && (monsterObj.HasBestiaryCapturedAura || monsterObj.HasBestiaryDisappearingAura)))

I'd like for us to test this first before just blindly including it, but you can test it locally after the next update.
 
Last edited:
Back
Top