Move to attack then return again
skippy
Member Posts: 106
Guy's i've read about moving actors back and fourth etc, but i can't work out how to do this.
When an enemy actor is triggered by colliding with a main actor and he move's to position say 120 while doing an animation then he fire's or whatever how then after the main actor has left his trigger area do you get him to return back to where he started from so if you come back to his area he is ready to attack you again ? Iv'e tried a couple of ways with no results so basically what i want is main actor has triggered enemy, enemy moves to position and keeps spawning stuff until main actor isn't colliding anymore now i want enemy to go back to starting position and do it again if main actor collides again.
When an enemy actor is triggered by colliding with a main actor and he move's to position say 120 while doing an animation then he fire's or whatever how then after the main actor has left his trigger area do you get him to return back to where he started from so if you come back to his area he is ready to attack you again ? Iv'e tried a couple of ways with no results so basically what i want is main actor has triggered enemy, enemy moves to position and keeps spawning stuff until main actor isn't colliding anymore now i want enemy to go back to starting position and do it again if main actor collides again.
Comments
I've tried making boolean attributes as well but i might be doing it wrong and i'm not sure if i should be using "when actor overlaps or collides" or rather just attributes.
What i have now in enemy actor : is when actor overlaps or collides with main guy
animate sequence
move to position 120
timer (every 1.5 sec spawn object)
But then when main guy moves away and comes back again enemy is still at the same 120 position and then will move to position again now 240 but now he's too far. Also i v'e tried otherwise move to position -120 with an animation going back but no good.
I need the enemy to move to when the main guy's there and then move back when not type thing. I also tried putting an invisible trigger at the right spot so when the main guy touches it
it triggers the enemy to do his stuff but i'm still messing it up somehow.