Nukie win conditions (#10220)

Co-authored-by: Kara <lunarautomaton6@gmail.com>
This commit is contained in:
Flipp Syder
2022-09-13 19:42:19 -07:00
committed by GitHub
parent 053c70d8d5
commit ffbd0085bc
5 changed files with 334 additions and 40 deletions

View File

@@ -519,7 +519,10 @@ namespace Content.Server.Nuke
component.IntensitySlope,
component.MaxIntensity);
RaiseLocalEvent(new NukeExplodedEvent());
RaiseLocalEvent(new NukeExplodedEvent()
{
OwningStation = transform.GridUid,
});
_soundSystem.StopStationEventMusic(component.Owner, StationEventMusicType.Nuke);
EntityManager.DeleteEntity(uid);
@@ -546,6 +549,7 @@ namespace Content.Server.Nuke
{
TargetCancelledEvent = new NukeDisarmCancelledEvent(),
TargetFinishedEvent = new NukeDisarmSuccessEvent(),
BroadcastFinishedEvent = new NukeDisarmSuccessEvent(),
BreakOnDamage = true,
BreakOnStun = true,
BreakOnTargetMove = true,
@@ -570,7 +574,10 @@ namespace Content.Server.Nuke
}
}
public sealed class NukeExplodedEvent : EntityEventArgs {}
public sealed class NukeExplodedEvent : EntityEventArgs
{
public EntityUid? OwningStation;
}
/// <summary>
/// Raised directed on the nuke when its disarm doafter is successful.