mirror of
https://github.com/wega-team/ss14-wega.git
synced 2026-02-14 19:30:01 +01:00
[Staging] Let admins ignore the laws of physics again. (#42221)
admin ignore physics Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
bbc519c523
commit
6cefe4299d
@@ -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
|
||||
|
||||
@@ -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:
|
||||
|
||||
Reference in New Issue
Block a user