edited January 25 in ORK Support
So I have an enemy that I want to flee from the player.
I got that part to work, but it will only flee.

I want it to flee and attack. It has an attack that simply spawns a prefab and moves it forward towards the player.

The weird thing is, when I have it attack, it stops fleeing, instead it will Hunt, even if the moveAI doesnt have hunt enabled.

Basically, I can have it attack, but it will hunt. If I have it flee, it wont attack.

Any ideas?
Post edited by Wrofir on
Warborn
  • Make sure your move AI's Use Mode is in Flee mode. You can either set that in the move AI's settings or change it via the battle AI and the event system.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited January 28
    I did that. Now what happens is that opponent will hunt and then flee over and over again. move away and then moving back switching between them every second or so.

    Use mode in the move AI is set to Flee, and its currently not using a battle AI or behaviour
    Post edited by Wrofir on
    Warborn
  • If the combatant is out of use range of the attack, he'll move toward the target, so that's probably what's happening.

    If you want to prevent this, you need to set up your battle AI to only use targets within range of that attack.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I dont think that's it, as he starts attacking much further away, and will continue to move towards me regardless of how close i am.

    Ill try and remake him from scratch later on and see if maybe I messed up a setting somewhere along the way.
    Warborn
  • If it keeps happening, I'd best need a Unity demo project with your setup to check it out :)
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Always appreciated! :D
    Warborn
Sign In or Register to comment.