Fixes Syndicate Bomb logs (#20240)
* Fixed logs * fix dumb entity stuff
This commit is contained in:
@@ -136,7 +136,7 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
{
|
{
|
||||||
_trigger.HandleTimerTrigger(
|
_trigger.HandleTimerTrigger(
|
||||||
uid,
|
uid,
|
||||||
null,
|
user,
|
||||||
timerTrigger.Delay,
|
timerTrigger.Delay,
|
||||||
timerTrigger.BeepInterval,
|
timerTrigger.BeepInterval,
|
||||||
timerTrigger.InitialBeepDelay,
|
timerTrigger.InitialBeepDelay,
|
||||||
@@ -147,14 +147,12 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
RaiseLocalEvent(uid, new BombArmedEvent(uid));
|
RaiseLocalEvent(uid, new BombArmedEvent(uid));
|
||||||
|
|
||||||
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):entity} begun a countdown on {ToPrettyString(uid):entity}");
|
|
||||||
|
|
||||||
if (TryComp<WiresPanelComponent>(uid, out var wiresPanelComponent))
|
if (TryComp<WiresPanelComponent>(uid, out var wiresPanelComponent))
|
||||||
_wiresSystem.TogglePanel(uid, wiresPanelComponent, false);
|
_wiresSystem.TogglePanel(uid, wiresPanelComponent, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void TryDetonateBomb(EntityUid uid, DefusableComponent comp)
|
public void TryDetonateBomb(EntityUid uid, EntityUid detonator, DefusableComponent comp)
|
||||||
{
|
{
|
||||||
if (!comp.Activated)
|
if (!comp.Activated)
|
||||||
return;
|
return;
|
||||||
@@ -163,13 +161,10 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
|
|
||||||
RaiseLocalEvent(uid, new BombDetonatedEvent(uid));
|
RaiseLocalEvent(uid, new BombDetonatedEvent(uid));
|
||||||
|
|
||||||
_explosion.TriggerExplosive(uid);
|
_explosion.TriggerExplosive(uid, user:detonator);
|
||||||
QueueDel(uid);
|
QueueDel(uid);
|
||||||
|
|
||||||
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(uid):entity} has been detonated.");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void TryDefuseBomb(EntityUid uid, DefusableComponent comp)
|
public void TryDefuseBomb(EntityUid uid, DefusableComponent comp)
|
||||||
@@ -204,8 +199,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_transform.Unanchor(uid, xform);
|
_transform.Unanchor(uid, xform);
|
||||||
|
|
||||||
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
_appearance.SetData(uid, DefusableVisuals.Active, comp.Activated);
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(uid):entity} has been defused!");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// jesus christ
|
// jesus christ
|
||||||
@@ -249,9 +242,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_trigger.TryDelay(wire.Owner, 30f);
|
_trigger.TryDelay(wire.Owner, 30f);
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-chirp", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-chirp", ("name", wire.Owner)), wire.Owner);
|
||||||
comp.DelayWireUsed = true;
|
comp.DelayWireUsed = true;
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the DeLAY wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool ProceedWireCut(EntityUid user, Wire wire, DefusableComponent comp)
|
public bool ProceedWireCut(EntityUid user, Wire wire, DefusableComponent comp)
|
||||||
@@ -262,9 +252,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-proceed-pulse", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-proceed-pulse", ("name", wire.Owner)), wire.Owner);
|
||||||
SetDisplayTime(comp, false);
|
SetDisplayTime(comp, false);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} cut the PRoCeeD wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
|
|
||||||
comp.ProceedWireCut = true;
|
comp.ProceedWireCut = true;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -277,9 +264,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_trigger.TryDelay(wire.Owner, -15f);
|
_trigger.TryDelay(wire.Owner, -15f);
|
||||||
}
|
}
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the PRoCeeD wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
|
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-proceed-pulse", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-proceed-pulse", ("name", wire.Owner)), wire.Owner);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -295,9 +279,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
$"{ToPrettyString(user):user} has defused {ToPrettyString(wire.Owner):entity}!");
|
$"{ToPrettyString(user):user} has defused {ToPrettyString(wire.Owner):entity}!");
|
||||||
}
|
}
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} cut the LIVE wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -313,15 +294,11 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_trigger.TryDelay(wire.Owner, 30f);
|
_trigger.TryDelay(wire.Owner, 30f);
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-chirp", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-chirp", ("name", wire.Owner)), wire.Owner);
|
||||||
comp.ActivatedWireUsed = true;
|
comp.ActivatedWireUsed = true;
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the LIVE wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
TryStartCountdown(wire.Owner, user, comp);
|
TryStartCountdown(wire.Owner, user, comp);
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the LIVE wire of {ToPrettyString(wire.Owner):entity} and begun the countdown.");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -329,15 +306,11 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
{
|
{
|
||||||
if (comp.Activated)
|
if (comp.Activated)
|
||||||
{
|
{
|
||||||
EntityManager.System<DefusableSystem>().TryDetonateBomb(wire.Owner, comp);
|
TryDetonateBomb(wire.Owner, user, comp);
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.Extreme,
|
|
||||||
$"{ToPrettyString(user):user} cut the BOOM wire of {ToPrettyString(wire.Owner):entity} and caused it to detonate!");
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
EntityManager.System<DefusableSystem>().SetUsable(comp, false);
|
SetUsable(comp, false);
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} cut the BOOM wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -347,9 +320,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
if (comp is { Activated: false, Usable: false })
|
if (comp is { Activated: false, Usable: false })
|
||||||
{
|
{
|
||||||
SetUsable(comp, true);
|
SetUsable(comp, true);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} mended the BOOM wire of {ToPrettyString(wire.Owner):entity}.");
|
|
||||||
}
|
}
|
||||||
// you're already dead lol
|
// you're already dead lol
|
||||||
return true;
|
return true;
|
||||||
@@ -359,10 +329,8 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
{
|
{
|
||||||
if (comp.Activated)
|
if (comp.Activated)
|
||||||
{
|
{
|
||||||
TryDetonateBomb(wire.Owner, comp);
|
TryDetonateBomb(wire.Owner, user, comp);
|
||||||
}
|
}
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.Extreme,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the BOOM wire of {ToPrettyString(wire.Owner):entity} and caused it to detonate!");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool BoltWireMend(EntityUid user, Wire wire, DefusableComponent comp)
|
public bool BoltWireMend(EntityUid user, Wire wire, DefusableComponent comp)
|
||||||
@@ -374,9 +342,6 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_audio.PlayPvs(comp.BoltSound, wire.Owner);
|
_audio.PlayPvs(comp.BoltSound, wire.Owner);
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} mended the BOLT wire of {ToPrettyString(wire.Owner):entity}!");
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -389,18 +354,12 @@ public sealed class DefusableSystem : SharedDefusableSystem
|
|||||||
_audio.PlayPvs(comp.BoltSound, wire.Owner);
|
_audio.PlayPvs(comp.BoltSound, wire.Owner);
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} cut the BOLT wire of {ToPrettyString(wire.Owner):entity}!");
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void BoltWirePulse(EntityUid user, Wire wire, DefusableComponent comp)
|
public void BoltWirePulse(EntityUid user, Wire wire, DefusableComponent comp)
|
||||||
{
|
{
|
||||||
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
_popup.PopupEntity(Loc.GetString("defusable-popup-wire-bolt-pulse", ("name", wire.Owner)), wire.Owner);
|
||||||
|
|
||||||
_adminLogger.Add(LogType.Explosion, LogImpact.High,
|
|
||||||
$"{ToPrettyString(user):user} pulsed the BOLT wire of {ToPrettyString(wire.Owner):entity}!");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
Reference in New Issue
Block a user