From 834b2e4d58dfcba10bee621e8f9e7c94eb17a9a1 Mon Sep 17 00:00:00 2001 From: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Date: Thu, 3 Mar 2022 13:32:03 +1100 Subject: [PATCH] Disable pushing (#6760) --- Content.Shared/CCVar/CCVars.cs | 2 +- .../Movement/EntitySystems/SharedMobMoverSystem.cs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Content.Shared/CCVar/CCVars.cs b/Content.Shared/CCVar/CCVars.cs index 9935f118bd..5e0e20d96a 100644 --- a/Content.Shared/CCVar/CCVars.cs +++ b/Content.Shared/CCVar/CCVars.cs @@ -291,7 +291,7 @@ namespace Content.Shared.CCVar /// Technically client doesn't need to know about it but this may prevent a bug in the distant future so it stays. /// public static readonly CVarDef MobPushing = - CVarDef.Create("physics.mob_pushing", true, CVar.REPLICATED); + CVarDef.Create("physics.mob_pushing", false, CVar.REPLICATED); /* * Lobby music diff --git a/Content.Shared/Movement/EntitySystems/SharedMobMoverSystem.cs b/Content.Shared/Movement/EntitySystems/SharedMobMoverSystem.cs index 389df8402a..121c28836b 100644 --- a/Content.Shared/Movement/EntitySystems/SharedMobMoverSystem.cs +++ b/Content.Shared/Movement/EntitySystems/SharedMobMoverSystem.cs @@ -16,7 +16,7 @@ namespace Content.Shared.Movement.EntitySystems public override void Initialize() { base.Initialize(); - Get().KinematicControllerCollision += HandleCollisionMessage; + Get().KinematicControllerCollision += OnMobCollision; IoCManager.Resolve().OnValueChanged(CCVars.MobPushing, SetPushing, true); } @@ -29,13 +29,13 @@ namespace Content.Shared.Movement.EntitySystems { base.Shutdown(); IoCManager.Resolve().UnsubValueChanged(CCVars.MobPushing, SetPushing); - Get().KinematicControllerCollision -= HandleCollisionMessage; + Get().KinematicControllerCollision -= OnMobCollision; } /// /// Fake pushing for player collisions. /// - private void HandleCollisionMessage(Fixture ourFixture, Fixture otherFixture, float frameTime, Vector2 worldNormal) + private void OnMobCollision(Fixture ourFixture, Fixture otherFixture, float frameTime, Vector2 worldNormal) { if (!_pushingEnabled) return;