Make multiple enemies? (PLATFORMER)

0 favourites
  • 6 posts
From the Asset Store
10 Retro songs ideal for platformers or farming games
  • I'm having problems making multiple enemies in a side scrolling platformer game. I made a Family and grouped together the same kind of enemies and placed 2 in the Layout. They both seem to go only one direction even if I'm right between them (They're both going left even when the other is supposed to go right).

    Their behaviors are Platform and Bullet. I use Platform in the Event to move them around (SIMULATE PRESSING). Is there a better way to have more than one enemy of the same type on screen at the same time?

  • Do you have a capx? from the description you give I can't get enough information.

    It's possible to have many enemies on the screen at the same time, but if you want them to behave differently you have to set it up in your events.

  • Do you mean making a different event for each enemy on the screen? I've tried making a separate Family and Event for the movement but it still resulted the same..

    Here's the capx file just in case:

    mediafire.com/download/wpi19q3kss365at/test.capx

  • leolr9

    this solution works. Here's the capx file:

    dl.dropboxusercontent.com/u/417253/new.capx

    I created a for each loop to go through each object in the walkers family

    so it's like this (just in case capx file link goes dead in future):

    for each walker{

       if player.x < walkers.x

          simulate platform left

          set mirrored

       if player.x > walkers.x

          simulate platform right

          set not mirrored

    }

  • p.s. i like the art in your game. Did you do it yourself?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Oh didn't think about that. Thanks a lot! This works <img src="smileys/smiley1.gif" border="0" align="middle" />

    PS: Yeah, it was pretty rushed. Thanks :)

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