Hi, I have a "small" problem.
What I want to do is have an enemy with 2 attacks, 1 which is close range and a
projectile attack. I want the enemy to be in Idle for 4 second, then use the projectile attack, the animation would repeat 3 times as he has to shoot for 3.6 sec, then he would be in idle for 1 sec, after he would walk toward the player for 5 sec then he would use the melee attack after that going back to idle to begin the loop again.
I just can't script this. I tried with variables, with groups activating and deactivating each other, with more variables. NOTHING WORKS. Either the walk animation is stuck or he wouldn't stop shooting or he wouldn't play the melee attack etc.
Also I would like to mention the enemy has 5 animations: Idle, Walk, Projectile attack, Melee attack and Death animation.
Please help, I have been trying for the past few days nothing works.