[SOLVED]PlatformerObject Behavior doesn't work with Physics 2.0

Hi everyone (first post here)!!
I have a player character with the Platformer Behavior and the Physics 2.0 Behavior (to interact with other Physics objects).
Next I want to set up a jumpthrough platform (an office desk) to have the player either walk past the desk or jump on it. The desk also has to have the physics behavior so that other objects can interact with it.
Unfortunately I can’t get it to work with all the behaviors. It only works if I deactivate the players physics behavior and I need him to interact with other objects physically. Thank you already for your help! It is much appreciated.

Yeah. Some behaviors don’t play well together especially ones that apply force. One might push up while the other pushes towards the left. It can create a jeky motion and a popping effect.

You can disable/enable behaviors. Remember objects don’t need to be visit to work. So, you can add as many visible or hidden objects as is needed within a limit.

At the bottom of the physics behavior there is also options to set objects to certain layers. (this has nothing to do with scene layers, these are unique to the physics) You can have some physics objects only interact with other physics objects.

There are probably ways to do things with just one behavior. I would recommend you try to find a way. Just ask and we’ll try to help.

1 Like

I’m going to try changing layers triggered by a collision of the player with a hidden object.
Thanks a lot, Keith!
Will update here if it works.

1 Like

I tried putting the player and the desk on different layers within their physics behaviours, but still the jumpthru platform wasn’t working (but the normal platform behaviour did). So in addition to the separation of layers for physics I set up two sprites, one attached to the player (red), the other just fixed above the desk (blue). If they collide it would activate the normal platform behaviour of the desk (has to be deactivated at beginning of the scene) and than the player would land on it. So basically I build my own jumpthru platform without the regular behaviour option for that purpose.
Everything works just fine now! Thank you Keith again for that quick and very helpful reply!!

1 Like

… almost everything. Jumping from the desk was glitching, so I had to deactivate the physics for the player again, if he collided with the desk collision mask but not the blue control sprite. Now the player can also jump from the platform.