How to use damage sense in behavior tree? (EQS)

Does anyone know how to use damage sense in EQS?
I have not been able to find an example for this specific EQS case.

I tried to do it myself but I couldn’t get it to work.
I tried to make it as simple as possible.

An environment query.

Captura de pantalla 2024-04-05 135300

And a task… But since the task does not work, also try a service. (It didn’t work either)

Captura de pantalla 2024-04-05 135423

This is the service code:

Just in case he also added the perception component in the AIController.

Damage is applied with “ApplyDamage” function (This does work).

Does anyone know how to use this EQS correctly?

Thank you so much!!

1 Like

I found out “ApplyDamage()” function does not trigger the “OnTargetPerceptionUpdated” event of AAIControler.

So, to use some of this function is needed to get trigget it.

And i got capture the event like this:

This way does work… however the EQS still does not working.

I have not idea why…

I just want the instigator pawn reference to convert it in a new enemy and follow it.
And will be excelent if i can do everything inside of the behavior tree.

Any idea is wellcome!!

Thank you so much!!

Ok, this does exactly what i want…

I would prefer to use EQS because i can apply filters directly… but if no one knows how to use it i think this may work instead of EQS

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.