Fix a bunch of warnings (#10886)
* Fix a bunch of warnings Also made ensnareable not broadcast as they're only used directed. Mainly just Get<T> and AppearanceSystem * buckle too * fix tests Co-authored-by: wrexbe <wrexbe@protonmail.com>
This commit is contained in:
@@ -8,6 +8,8 @@ namespace Content.Shared.Foldable;
|
||||
[UsedImplicitly]
|
||||
public abstract class SharedFoldableSystem : EntitySystem
|
||||
{
|
||||
[Dependency] protected readonly SharedAppearanceSystem Appearance = default!;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
@@ -47,9 +49,7 @@ public abstract class SharedFoldableSystem : EntitySystem
|
||||
{
|
||||
component.IsFolded = folded;
|
||||
Dirty(component);
|
||||
|
||||
if (TryComp(component.Owner, out AppearanceComponent? appearance))
|
||||
appearance.SetData(FoldedVisuals.State, folded);
|
||||
Appearance.SetData(component.Owner, FoldedVisuals.State, folded);
|
||||
}
|
||||
|
||||
private void OnInsertEvent(EntityUid uid, FoldableComponent component, ContainerGettingInsertedAttemptEvent args)
|
||||
|
||||
Reference in New Issue
Block a user