From: Princess Cheeseballs <66055347+Princess-Cheeseballs@users.noreply.github.com> Date: Sat, 3 Jan 2026 19:39:17 +0000 (-0800) Subject: [Staging] Let admins ignore the laws of physics again. (#42221) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=6cefe4299d39fefc421ae754f4b419634d40ff92;p=space-station-14.git [Staging] Let admins ignore the laws of physics again. (#42221) admin ignore physics Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com> --- diff --git a/Content.Shared/Movement/Systems/SharedMoverController.cs b/Content.Shared/Movement/Systems/SharedMoverController.cs index b3607b8463..bda05da019 100644 --- a/Content.Shared/Movement/Systems/SharedMoverController.cs +++ b/Content.Shared/Movement/Systems/SharedMoverController.cs @@ -218,11 +218,13 @@ public abstract partial class SharedMoverController : VirtualController * Physics simulation, which will cause issues for Dynamic bodies (Such as Friction being applied twice). * Kinematic bodies have even less Physics options and as such aren't suitable for a player, especially * when we move to Box2D v3 where there will be more support for players updating outside of simulation. + * However, Kinematic bodies are useful currently for mobs which explicitly ignore physics, you should use + * this type extremely sparingly and only for mobs which *explicitly* disobey the laws of physics (A-Ghosts). * Lastly, static bodies can't move so they shouldn't be updated. If a static body makes it here we're * doing unnecessary calculations. * Only a Kinematic Controller should be making it to this point. */ - DebugTools.Assert(physicsComponent.BodyType == BodyType.KinematicController, + DebugTools.Assert(physicsComponent.BodyType == BodyType.KinematicController || physicsComponent.BodyType == BodyType.Kinematic, $"Input mover: {ToPrettyString(uid)} in HandleMobMovement is not the correct BodyType, BodyType found: {physicsComponent.BodyType}, expected: KinematicController."); // If the body is in air but isn't weightless then it can't move diff --git a/Resources/Prototypes/Entities/Mobs/Player/admin_ghost.yml b/Resources/Prototypes/Entities/Mobs/Player/admin_ghost.yml index 088c0f3ba1..ccfa2cec73 100644 --- a/Resources/Prototypes/Entities/Mobs/Player/admin_ghost.yml +++ b/Resources/Prototypes/Entities/Mobs/Player/admin_ghost.yml @@ -36,6 +36,7 @@ needsHands: false - type: CombatMode - type: Physics + bodyType: Kinematic # Admin ghosts should ignore the laws of physics. ignorePaused: true - type: Access groups: