Help with choosing boss attack!

0 favourites
  • 5 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • I have made a boss with 3 different attacks. I am using the Finite State Machine add-on to make the states.

    I have an "AttackNumber" variable that starts at 0. If it's set to 1 it goes to Attack1Start state, and so on.

    These are the important states the boss has:

    Follow (to follow the player around)

    Choose attack

    And a start, middle, and finish state for all 3 attacks.

    The problem is that when I tell it to set "AttackNumber" to choose(1,2,3) it instead tries to do all 3 attacks at once even though the variable is set to one number.

    Each attack works fine if I tell it to set the variable to a specific number though.

  • Not sure what the add on is but need to see a screenshot of the events

  • Im gonna guess that it's a timing issue. Set a condition that waits for the attack animation to finish before 'choose(1,2,3)', or the attack state to be zero, or whatever feels right.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I wasn't able to get random attacks to work no matter what I did, so I tried making it do the attacks in order and it worked just fine. So that's what I've been sticking with now lol. Thanks for trying to help though!

  • Maybe try adding 'Trigger Once' to your event that chooses the attack routine? Sounds like it might be repeating the command over and over because there's nothing telling it not to.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)