Implement ECS alternative for IDragDropOn and fully ECS disposal units (#6380)

Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
Julian Giebel
2022-01-30 17:53:22 +01:00
committed by GitHub
parent 1bece1c1ba
commit 305cff2659
10 changed files with 147 additions and 128 deletions

View File

@@ -9,7 +9,7 @@ using Robust.Shared.Serialization;
namespace Content.Shared.Disposal.Components
{
[NetworkedComponent]
public abstract class SharedDisposalUnitComponent : Component, IDragDropOn
public abstract class SharedDisposalUnitComponent : Component
{
public override string Name => "DisposalUnit";
@@ -134,13 +134,5 @@ namespace Content.Shared.Disposal.Components
{
Key
}
// TODO: Unfortunately these aren't really ECS yet so soontm
public virtual bool CanDragDropOn(DragDropEvent eventArgs)
{
return EntitySystem.Get<SharedDisposalUnitSystem>().CanInsert(this, eventArgs.Dragged);
}
public abstract bool DragDropOn(DragDropEvent eventArgs);
}
}