platform behavior behind solid

0 favourites
  • 6 posts
From the Asset Store
A pack of 76 platform designs for a platformer game with a mushroom/jungle theme
  • hi,

    in some cases my player (platform behavior) move behind solid objects. see screenshot.

    i'm using

    touch is in touch - player move forward 1 pixels

    thanks

  • "Player move forward one pixel" is not using the platformer behavior, and therefore can move through solid objects. (but will not fall through them.)

    You might want "Platformer Simulate Control Right"

  • Or if you want to keep it the way you did it, just put all your solid objects into a family (which you could call "solids") and then add a second condition to your event to make sure that it runs only when your player isn't overlapping any object from the "solids" family.

    • Touch : is in touch
    • Player : isn't overlapping "solids"

    > Player : move forward 1 pixel

  • Won't it be overlapping when it's standing on a solid?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Kan

    Unnatural20

    thx for your tips, i'll try both of them.

    just wonder why it only happens in some cases. i added the platform behavior only to prevent moving through solids.

    forgott to mention that i've also a condition

    touch is in touch - set player angle touch.x touch.y

    maybe it has to do with the angle condition

    thx!

  • metameta : I think it might have more to do with the angle position indeed.

    Unnatural20 : From what I could see, behaviours that are packed with Construct handle collision with solids differently than how you or I could handle it. So no, a platformer object standing on a solid is apparently not "overlapping" the solid (I had to use "overlap at offset" to check on which solid object my player was standing in a platformer game I made).

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