Predict and cleanup RingerComponent (#35907)
* clean up most stuff * move to shared * works * shuffle shit around * oops! access * fixes * todo: everything * SUFFERING * curse you
This commit is contained in:
@@ -10,15 +10,16 @@ using Content.Server.Traitor.Uplink;
|
||||
using Content.Shared.Access.Components;
|
||||
using Content.Shared.CartridgeLoader;
|
||||
using Content.Shared.Chat;
|
||||
using Content.Shared.DeviceNetwork.Components;
|
||||
using Content.Shared.Light;
|
||||
using Content.Shared.Light.EntitySystems;
|
||||
using Content.Shared.PDA;
|
||||
using Content.Shared.PDA.Ringer;
|
||||
using Robust.Server.Containers;
|
||||
using Robust.Server.GameObjects;
|
||||
using Robust.Shared.Containers;
|
||||
using Robust.Shared.Player;
|
||||
using Robust.Shared.Utility;
|
||||
using Content.Shared.DeviceNetwork.Components;
|
||||
|
||||
namespace Content.Server.PDA
|
||||
{
|
||||
@@ -166,7 +167,7 @@ namespace Content.Server.PDA
|
||||
/// <summary>
|
||||
/// Send new UI state to clients, call if you modify something like uplink.
|
||||
/// </summary>
|
||||
public void UpdatePdaUi(EntityUid uid, PdaComponent? pda = null)
|
||||
public override void UpdatePdaUi(EntityUid uid, PdaComponent? pda = null)
|
||||
{
|
||||
if (!Resolve(uid, ref pda, false))
|
||||
return;
|
||||
@@ -243,7 +244,7 @@ namespace Content.Server.PDA
|
||||
return;
|
||||
|
||||
if (HasComp<RingerComponent>(uid))
|
||||
_ringer.ToggleRingerUI(uid, msg.Actor);
|
||||
_ringer.TryToggleRingerUi(uid, msg.Actor);
|
||||
}
|
||||
|
||||
private void OnUiMessage(EntityUid uid, PdaComponent pda, PdaShowMusicMessage msg)
|
||||
@@ -272,7 +273,7 @@ namespace Content.Server.PDA
|
||||
|
||||
if (TryComp<RingerUplinkComponent>(uid, out var uplink))
|
||||
{
|
||||
_ringer.LockUplink(uid, uplink);
|
||||
_ringer.LockUplink((uid, uplink));
|
||||
UpdatePdaUi(uid, pda);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user