[Platformer] Possible Collision bug

0 favourites
  • 4 posts
From the Asset Store
Match same tiles with each other as fast as you can and earn more score during a limited time!
  • Link to .capx file (required!):

    dl.dropboxusercontent.com/u/88974109/Skyrunner.capx

    Steps to reproduce:

    1. Simply watch the game play out.

    2.

    3.

    Observed result:

    The enemyBox does not honor the collision with the enemyHolder

    Expected result:

    The enemyBox should change directions when colliding with the enemyHolder.

    Browsers affected:

    Chrome: yes

    Firefox: yes

    Internet Explorer: yes

    Operating system & service pack:

    Windows 7 no SP

    Construct 2 version:

    v132 Free Edition

  • This is a bug in your events.

    On the Enemies event sheet, events 4 and 5 are checking for a direction, changing it, and the very next event changes it back.

    You should make this an Else, i.e.

    enemysprite direction = "right" : enemysprite set direction to "left"

    Else

    enemysprite direction = "left" : enemysprite set direction to "right"

    This should really have been posted in the 'How Do I' section.

  • Thanks Zenox, that did fix it. I'm still not quite sure why though. I'm assuming that it's doing both actions, but the second option isn't true in that specific instance.

    Either way, the else function worked just fine.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Alright, I just realized why I didn't use the else function. It's because I have multiple instances of the enemy and I can't get them to act independently. I'm going to ask that this topic be moved to the "How do I..." section by any moderator that can do me the favor.

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