Wearable Wet Floor Sign and 'Janitorial Suicide Vest' (#20311)
* Explosive wet floor sign & janitorial suicide vest * fix attributions * Remove name & desc from explosive wet floor sign * Make wet floor sign chameleonable
This commit is contained in:
@@ -48,6 +48,32 @@ public sealed partial class TriggerSystem
|
||||
if (!args.CanInteract || !args.CanAccess)
|
||||
return;
|
||||
|
||||
if (component.UseVerbInstead)
|
||||
{
|
||||
args.Verbs.Add(new AlternativeVerb()
|
||||
{
|
||||
Text = Loc.GetString("verb-start-detonation"),
|
||||
Act = () => HandleTimerTrigger(
|
||||
uid,
|
||||
args.User,
|
||||
component.Delay,
|
||||
component.BeepInterval,
|
||||
component.InitialBeepDelay,
|
||||
component.BeepSound
|
||||
),
|
||||
Priority = 2
|
||||
});
|
||||
}
|
||||
|
||||
if (component.AllowToggleStartOnStick)
|
||||
{
|
||||
args.Verbs.Add(new AlternativeVerb()
|
||||
{
|
||||
Text = Loc.GetString("verb-toggle-start-on-stick"),
|
||||
Act = () => ToggleStartOnStick(uid, args.User, component)
|
||||
});
|
||||
}
|
||||
|
||||
if (component.DelayOptions == null || component.DelayOptions.Count == 1)
|
||||
return;
|
||||
|
||||
@@ -86,15 +112,6 @@ public sealed partial class TriggerSystem
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
if (component.AllowToggleStartOnStick)
|
||||
{
|
||||
args.Verbs.Add(new AlternativeVerb()
|
||||
{
|
||||
Text = Loc.GetString("verb-toggle-start-on-stick"),
|
||||
Act = () => ToggleStartOnStick(uid, args.User, component)
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private void CycleDelay(OnUseTimerTriggerComponent component, EntityUid user)
|
||||
@@ -140,7 +157,7 @@ public sealed partial class TriggerSystem
|
||||
|
||||
private void OnTimerUse(EntityUid uid, OnUseTimerTriggerComponent component, UseInHandEvent args)
|
||||
{
|
||||
if (args.Handled || HasComp<AutomatedTimerComponent>(uid))
|
||||
if (args.Handled || HasComp<AutomatedTimerComponent>(uid) || component.UseVerbInstead)
|
||||
return;
|
||||
|
||||
HandleTimerTrigger(
|
||||
|
||||
Reference in New Issue
Block a user