Set mover velocity via system (#6288)

This commit is contained in:
metalgearsloth
2022-02-02 17:34:25 +11:00
committed by GitHub
parent 0349a854ac
commit 2e5808085d
12 changed files with 44 additions and 47 deletions

View File

@@ -19,7 +19,7 @@ namespace Content.Server.Audio
if (!EntityManager.TryGetComponent<AmbientSoundComponent>(uid, out var ambientSound)) return;
if (ambientSound.Enabled == args.Supply) return;
ambientSound.Enabled = args.Supply;
ambientSound.Dirty();
Dirty(ambientSound);
}
private void HandlePowerChange(EntityUid uid, AmbientOnPoweredComponent component, PowerChangedEvent args)
@@ -27,7 +27,7 @@ namespace Content.Server.Audio
if (!EntityManager.TryGetComponent<AmbientSoundComponent>(uid, out var ambientSound)) return;
if (ambientSound.Enabled == args.Powered) return;
ambientSound.Enabled = args.Powered;
ambientSound.Dirty();
Dirty(ambientSound);
}
}
}