PopupSystem public methods rejig (#12830)
This commit is contained in:
@@ -188,7 +188,7 @@ namespace Content.Server.Dragon
|
||||
// We can't predict the rift being destroyed anyway so no point adding weakened to shared.
|
||||
dragon.WeakenedAccumulator = dragon.WeakenedDuration;
|
||||
_movement.RefreshMovementSpeedModifiers(component.Dragon);
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-destroyed"), component.Dragon, Filter.Entities(component.Dragon));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-destroyed"), component.Dragon, component.Dragon);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -212,19 +212,19 @@ namespace Content.Server.Dragon
|
||||
{
|
||||
if (component.Weakened)
|
||||
{
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-weakened"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-weakened"), uid, uid);
|
||||
return;
|
||||
}
|
||||
|
||||
if (component.Rifts.Count >= RiftsAllowed)
|
||||
{
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-max"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-max"), uid, uid);
|
||||
return;
|
||||
}
|
||||
|
||||
if (component.Rifts.Count > 0 && TryComp<DragonRiftComponent>(component.Rifts[^1], out var rift) && rift.State != DragonRiftState.Finished)
|
||||
{
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-duplicate"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-duplicate"), uid, uid);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -233,7 +233,7 @@ namespace Content.Server.Dragon
|
||||
// Have to be on a grid fam
|
||||
if (!_mapManager.TryGetGrid(xform.GridUid, out var grid))
|
||||
{
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-anchor"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-anchor"), uid, uid);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -241,7 +241,7 @@ namespace Content.Server.Dragon
|
||||
{
|
||||
if (riftXform.Coordinates.InRange(EntityManager, xform.Coordinates, RiftRange))
|
||||
{
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-proximity", ("proximity", RiftRange)), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-proximity", ("proximity", RiftRange)), uid, uid);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -251,7 +251,7 @@ namespace Content.Server.Dragon
|
||||
if (!tile.IsSpace(_tileDef))
|
||||
continue;
|
||||
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-space-proximity", ("proximity", RiftTileRadius)), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("carp-rift-space-proximity", ("proximity", RiftTileRadius)), uid, uid);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -379,14 +379,14 @@ namespace Content.Server.Dragon
|
||||
});
|
||||
break;
|
||||
default:
|
||||
_popupSystem.PopupEntity(Loc.GetString("devour-action-popup-message-fail-target-alive"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("devour-action-popup-message-fail-target-alive"), uid, uid);
|
||||
break;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
_popupSystem.PopupEntity(Loc.GetString("devour-action-popup-message-structure"), uid, Filter.Entities(uid));
|
||||
_popupSystem.PopupEntity(Loc.GetString("devour-action-popup-message-structure"), uid, uid);
|
||||
|
||||
if (component.SoundStructureDevour != null)
|
||||
_audioSystem.PlayPvs(component.SoundStructureDevour, uid, component.SoundStructureDevour.Params);
|
||||
|
||||
Reference in New Issue
Block a user