private void OnStateEnteredSubscribers(EntityUid target, MobStateComponent component, MobState state)
{
+ // All of the state changes here should already be networked, so we do nothing if we are currently applying a
+ // server state.
+ if (_timing.ApplyingState)
+ return;
+
_blocker.UpdateCanMove(target); //update movement anytime a state changes
switch (state)
{
using Content.Shared.Standing;
using Robust.Shared.GameStates;
using Robust.Shared.Physics.Systems;
+using Robust.Shared.Timing;
namespace Content.Shared.Mobs.Systems;
[Dependency] private readonly StandingStateSystem _standing = default!;
[Dependency] private readonly ISharedAdminLogManager _adminLogger = default!;
[Dependency] private readonly ILogManager _logManager = default!;
+ [Dependency] private readonly IGameTiming _timing = default!;
private ISawmill _sawmill = default!;
public override void Initialize()