Hi there,
i’ve found this post here: Bug regression riding a moving body ignore collision
I thought this was fixed, but in my actually game i can “ride” into a wall if i stand on a moving plattform.
This is my plattform group setup:
this.plattforms = this.physics.add.group({
immovable: true,
allowGravity: false,
frictionX: 1,
});
this.physics.add.collider( this.hero, this.plattforms );
And this is where i move each plattform:
if( this.x <= this.startPos ){
this.body.setVelocityX( 50 );
}
if( this.x >= this.targetPos){
this.body.setVelocityX( -50 );
}
So if my player stands on this plattform, he get transported as expected. But if the plattform moves into a wall, hero is following and also moving in this wall. as soon as i move him a bit, collision is working again…
What am i missing?