void Update() {
if(Input.GetKeyDown(KeyCode.Space)) { Physics2D.IgnoreLayerCollision(9, 10, true);
}
else
if(rigBody.velocity.y < 0.05f)
{
Physics2D.IgnoreLayerCollision(9, 10, false);
}
}
basically what the problem is the ignorelayercollision doesn't work in some places of the collider for example if i have a large platform i want to jump onto its a straight edge collider and in certain places the collider isn't jumping through it acts as if there is no ignorecollider but if i move over just a few centimeters then it works.
↧