Remove some obsolete AppearanceComponent method usages (#13726)
This commit is contained in:
@@ -24,13 +24,10 @@ public sealed class MorgueSystem : EntitySystem
|
||||
/// </summary>
|
||||
private void OnExamine(EntityUid uid, MorgueComponent component, ExaminedEvent args)
|
||||
{
|
||||
if (!TryComp<AppearanceComponent>(uid, out var appearance))
|
||||
return;
|
||||
|
||||
if (!args.IsInDetailsRange)
|
||||
return;
|
||||
|
||||
appearance.TryGetData(MorgueVisuals.Contents, out MorgueContents contents);
|
||||
_appearance.TryGetData<MorgueContents>(uid, MorgueVisuals.Contents, out var contents);
|
||||
|
||||
var text = contents switch
|
||||
{
|
||||
@@ -92,7 +89,7 @@ public sealed class MorgueSystem : EntitySystem
|
||||
|
||||
comp.AccumulatedFrameTime -= comp.BeepTime;
|
||||
|
||||
if (comp.DoSoulBeep && appearance.TryGetData(MorgueVisuals.Contents, out MorgueContents contents) && contents == MorgueContents.HasSoul)
|
||||
if (comp.DoSoulBeep && _appearance.TryGetData<MorgueContents>(appearance.Owner, MorgueVisuals.Contents, out var contents, appearance) && contents == MorgueContents.HasSoul)
|
||||
{
|
||||
_audio.PlayPvs(comp.OccupantHasSoulAlarmSound, comp.Owner);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user