Players are propelled forward when slipping (#7886)

* Slippery System checks if players are already down before slipping them again. Prevents chains of banana peels accelerating players to supersonic speeds.

* Slippery items and puddles now propel people, some more than others.

* a white space
This commit is contained in:
hubismal
2022-05-01 01:02:29 -05:00
committed by GitHub
parent 2881cd4020
commit 6ec1572dd6
5 changed files with 11 additions and 1 deletions

View File

@@ -91,6 +91,11 @@ namespace Content.Shared.Slippery
return false;
}
if (EntityManager.HasComponent<KnockedDownComponent>(otherBody.Owner))
{
return false;
}
var ev = new SlipAttemptEvent();
RaiseLocalEvent(otherBody.Owner, ev, false);
if (ev.Cancelled)