* Теперь проще убирать следы
Signed-off-by: pacable <igor.mamaev1@gmail.com>
* чистобот чистит грязь лучше
Signed-off-by: pacable <igor.mamaev1@gmail.com>
* Revert "добавление возможности выключать следы (#655)"
This reverts commit ae78fa10
Signed-off-by: pacable <igor.mamaev1@gmail.com>
* postfix
Signed-off-by: pacable <igor.mamaev1@gmail.com>
* исправление чистящих гранат по отношению к следам
Signed-off-by: pacable <igor.mamaev1@gmail.com>
---------
Signed-off-by: pacable <igor.mamaev1@gmail.com>
24 lines
714 B
C#
24 lines
714 B
C#
using Content.Shared._Sunrise.Footprints;
|
|
using Robust.Shared.Physics.Events;
|
|
|
|
namespace Content.Server._Sunrise.Cleaning;
|
|
|
|
public sealed class FoorprintAreaCleaningSystem : EntitySystem
|
|
{
|
|
[Dependency] private readonly EntityManager _entMan = default!;
|
|
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
|
|
SubscribeLocalEvent<FootprintAreaCleanerComponent, StartCollideEvent>(OnCollide);
|
|
}
|
|
|
|
private void OnCollide(EntityUid uid, FootprintAreaCleanerComponent component, StartCollideEvent args)
|
|
{
|
|
if (!TryComp<FootprintComponent>(args.OtherEntity, out _) || !component.Enabled)
|
|
return;
|
|
|
|
_entMan.QueueDeleteEntity(args.OtherEntity);
|
|
}
|
|
}
|