This commit is contained in:
2022-01-29 12:21:38 +01:00
parent b326ddc304
commit 97680bbe87
2 changed files with 81 additions and 410 deletions

View File

@@ -102,11 +102,11 @@ public class PlayerController : MonoBehaviour
return;
}
Physics.gravity = this.downDirection * 9.81f;
if (platform.type == PlatformManager.PlatformType.SpeedUp)
{
// if (platform.type == PlatformManager.PlatformType.SpeedUp)
// {
angle = Mathf.Atan2(Vector3.Magnitude(axis), Vector3.Dot(-transform.up, -other.GetContact(0).normal));
transform.RotateAround(axis, angle);
}
// }
// TODO: Handle other PlatformTypes
Physics.gravity = this.downDirection * 9.81f;