How to achieve patterned enemy attack?

0 favourites
  • 3 posts
From the Asset Store
Enemy turtles pack including fifteen fully animated variations
  • Hi constructers:) Im using C2

    I would love to ask one question.

    I plan to have a static enemy, that:

    1.At first rest(idle) and then

    2.Attack left side and back to rest

    3.Attack right side and back to rest.

    My mind cant think well right now, pls help me:)

    Thanks

  • Since you are using Construct 2 the first thing is to search the How do I FAQ for C2.

    You should post directly in the Construct 2 forum and not the Construct 3 one (I've moved your topic to the C2 forum).

    You are looking to do some finished-state machine.

    You will want to have instance variables in your enemy and (possibly) the timer behavior.

    According to the current state you will execute some specific events that modify what your enemy is doing.

    For example, step1, rest for a given time once during this step start a timer.

    When this timer hits, pass the enemy to step 2.

    When the enemy is in step 2 you modify its graphics and spawn/do whatever is supposed to be its attacks on its left side. When it is done (a series of actions is finished, or another timer) move it back to a state of rest, but consider the next step is going to be the step 3.

    And so on.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • OMG Thanks... I make a state for each action. Thanks:)

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