mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-09-01 17:47:24 +02:00
24 lines
730 B
C#
24 lines
730 B
C#
using JetBrains.Annotations;
|
|
using Robust.Server.Interfaces.Timing;
|
|
using Robust.Shared.GameObjects.Systems;
|
|
using Robust.Shared.IoC;
|
|
using System.Linq;
|
|
using Robust.Shared.GameObjects.Components;
|
|
|
|
namespace Robust.Server.GameObjects.EntitySystems
|
|
{
|
|
[UsedImplicitly]
|
|
public class PhysicsSystem : SharedPhysicsSystem
|
|
{
|
|
[Dependency] private readonly IPauseManager _pauseManager = default!;
|
|
|
|
/// <inheritdoc />
|
|
public override void Update(float frameTime)
|
|
{
|
|
SimulateWorld(frameTime,
|
|
RelevantEntities.Where(e => !e.Deleted && !_pauseManager.IsEntityPaused(e))
|
|
.Select(p => p.GetComponent<IPhysicsComponent>()).ToList());
|
|
}
|
|
}
|
|
}
|