How do I get rid of sliding on platform with physics

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

    I need some help. I posted about this before and it got answered by using the pin behaviour. Let me explain a little more briefly.

    I have a physics puzzle game. All objects have the physics behaviour. My moving platforms have the platform behaviour and physics behaviour, But when my object rolls onto the moving platform even though it is still, it slides side to side on the platform(this is without the pin behaviour) . I tried to use the pin behaviour with a time limit on so when the rolling object rolls or falls off(due to physics) then it pins to the platform. But this created a bad bug, if the rolling object rolls fast and then slows down and falls off, it hangs in the air pinning to the platforms position but in mid air instead and not on the platform or unpinning the object.

    I tried testing conditions for when the player velocity=0 but it didn't work

    Any help? Please, I would really appreciate it

  • As far as I know, to prevent weird and unexpected effects it's still:

    "Never use physics in combination with other behaviours"

  • Ahhh damn :/ And this is the only way I can do this. Since its optimized for mobile too..

  • Anyone have a solution? Please I am really in need of help

  • Couldn't you just move the platforms by setting it's position?

  • I currently have r173 installed, I'll have a look at it tomorrow morning and see if it works. Thank you for the help LittleStain!

  • Without seeing a .capx it's hard top be specific, but you can recreate the control of a platformer character by manipulating a physics object with forces and impulses.

  • Oh yes, I did try that but I didn't do it right, but I'll have a look just now haha just woke up

  • I took a look at your example, fairly simple and straight forward I should have thought about that.

    Just to clarify though, if I want to make it loop from left to right and left then right infinite times, do I just create a time frame to move a few pixels left then in a few seconds move to the right and loop that motion?

  • The real physics solution for this would be like this:

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hmmm that could work, I'm just worried it may slow my game down even more anyhow let me give it a try and then let you know

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