add mass-media system (#18251)
* Add Console, PDA news tab, and ringstone popup * Add English localization * Add mass-media console board to Advanced Entertainment resrarch * Fix misprint * Deleting unused libraries * Fix round restart problem * Fixing restart problem * Just another fix * Сode optimization * Code optimization
This commit is contained in:
@@ -2,6 +2,7 @@ using Content.Server.Store.Components;
|
||||
using Content.Server.Store.Systems;
|
||||
using Content.Shared.PDA;
|
||||
using Content.Shared.PDA.Ringer;
|
||||
using Content.Shared.Popups;
|
||||
using Content.Shared.Store;
|
||||
using Robust.Server.GameObjects;
|
||||
using Robust.Server.Player;
|
||||
@@ -19,6 +20,7 @@ namespace Content.Server.PDA.Ringer
|
||||
[Dependency] private readonly IRobustRandom _random = default!;
|
||||
[Dependency] private readonly UserInterfaceSystem _ui = default!;
|
||||
[Dependency] private readonly AudioSystem _audio = default!;
|
||||
[Dependency] private readonly SharedPopupSystem _popupSystem = default!;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
@@ -48,6 +50,18 @@ namespace Content.Server.PDA.Ringer
|
||||
private void RingerPlayRingtone(EntityUid uid, RingerComponent ringer, RingerPlayRingtoneMessage args)
|
||||
{
|
||||
EnsureComp<ActiveRingerComponent>(uid);
|
||||
|
||||
_popupSystem.PopupEntity(Loc.GetString("comp-ringer-vibration-popup"), uid, Filter.Pvs(uid, 0.05f), false, PopupType.Small);
|
||||
|
||||
UpdateRingerUserInterface(uid, ringer);
|
||||
}
|
||||
|
||||
public void RingerPlayRingtone(EntityUid uid, RingerComponent ringer)
|
||||
{
|
||||
EnsureComp<ActiveRingerComponent>(uid);
|
||||
|
||||
_popupSystem.PopupEntity(Loc.GetString("comp-ringer-vibration-popup"), uid, Filter.Pvs(uid, 0.05f), false, PopupType.Small);
|
||||
|
||||
UpdateRingerUserInterface(uid, ringer);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user