Hey
So basically it does work. But when I stand on the platform and switch the rotation 180 degrees my player doesn’t fall.
if (Input.GetKeyDown(KeyCode.S))
{
gameObject.GetComponent<PlatformEffector2D>().rotationalOffset = 180;
}
if (Input.GetKeyUp(KeyCode.S))
{
gameObject.GetComponent<PlatformEffector2D>().rotationalOffset = 0;
}
}
This is the code I use for that though I don’t think the problem lies there as I can see in scene view that the rotationalOffset did change correctly. Also, if I press the key S before I land on the platform it works. It only malfunctions if I already stand on the platform.
Did anyone else have this problem? Or are there some ideas where this sort of behavior comes from?
Thanks in advance