More salvage fixes (#15618)
This commit is contained in:
@@ -46,5 +46,6 @@ public enum ExpeditionStage : byte
|
|||||||
Added,
|
Added,
|
||||||
Running,
|
Running,
|
||||||
Countdown,
|
Countdown,
|
||||||
|
MusicCountdown,
|
||||||
FinalCountdown,
|
FinalCountdown,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -126,12 +126,17 @@ public sealed partial class SalvageSystem
|
|||||||
comp.Stage = ExpeditionStage.FinalCountdown;
|
comp.Stage = ExpeditionStage.FinalCountdown;
|
||||||
Announce(uid, Loc.GetString("salvage-expedition-announcement-countdown-seconds", ("duration", TimeSpan.FromSeconds(30).Seconds)));
|
Announce(uid, Loc.GetString("salvage-expedition-announcement-countdown-seconds", ("duration", TimeSpan.FromSeconds(30).Seconds)));
|
||||||
}
|
}
|
||||||
else if (comp.Stage < ExpeditionStage.Countdown && remaining < TimeSpan.FromMinutes(2))
|
else if (comp.Stage < ExpeditionStage.Countdown && remaining < TimeSpan.FromMinutes(5))
|
||||||
|
{
|
||||||
|
comp.Stage = ExpeditionStage.Countdown;
|
||||||
|
Announce(uid, Loc.GetString("salvage-expedition-announcement-countdown-minutes", ("duration", TimeSpan.FromMinutes(5).Minutes)));
|
||||||
|
}
|
||||||
|
else if (comp.Stage < ExpeditionStage.MusicCountdown && remaining < TimeSpan.FromMinutes(2))
|
||||||
{
|
{
|
||||||
// TODO: Some way to play audio attached to a map for players.
|
// TODO: Some way to play audio attached to a map for players.
|
||||||
comp.Stream = _audio.PlayGlobal(new SoundPathSpecifier("/Audio/Misc/salvage.ogg"),
|
comp.Stream = _audio.PlayGlobal(new SoundPathSpecifier("/Audio/Misc/salvage.ogg"),
|
||||||
Filter.BroadcastMap(Comp<MapComponent>(uid).MapId), true, AudioParams.Default.WithVolume(-7));
|
Filter.BroadcastMap(Comp<MapComponent>(uid).MapId), true, AudioParams.Default.WithVolume(-7));
|
||||||
comp.Stage = ExpeditionStage.Countdown;
|
comp.Stage = ExpeditionStage.MusicCountdown;
|
||||||
Announce(uid, Loc.GetString("salvage-expedition-announcement-countdown-minutes", ("duration", TimeSpan.FromMinutes(2).Minutes)));
|
Announce(uid, Loc.GetString("salvage-expedition-announcement-countdown-minutes", ("duration", TimeSpan.FromMinutes(2).Minutes)));
|
||||||
}
|
}
|
||||||
// Auto-FTL out any shuttles
|
// Auto-FTL out any shuttles
|
||||||
@@ -192,6 +197,12 @@ public sealed partial class SalvageSystem
|
|||||||
{
|
{
|
||||||
Announce(uid, Loc.GetString("salvage-expedition-structure-remaining", ("count", structure.Structures.Count)));
|
Announce(uid, Loc.GetString("salvage-expedition-structure-remaining", ("count", structure.Structures.Count)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (structure.Structures.Count == 0)
|
||||||
|
{
|
||||||
|
comp.Completed = true;
|
||||||
|
Announce(uid, Loc.GetString("salvage-expedition-completed"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,8 @@
|
|||||||
salvage-expedition-structure-examine = This is a [color=#B02E26]destruction[/color] objective
|
salvage-expedition-structure-examine = This is a [color=#B02E26]destruction[/color] objective
|
||||||
salvage-expedition-structure-remaining = {$count} structures remaining.
|
salvage-expedition-structure-remaining = {$count ->
|
||||||
|
[one] {$count} structure remaining.
|
||||||
|
*[other] {$count} structures remaining.
|
||||||
|
}
|
||||||
|
|
||||||
salvage-expedition-window-title = Salvage expeditions
|
salvage-expedition-window-title = Salvage expeditions
|
||||||
salvage-expedition-window-difficulty = Difficulty:
|
salvage-expedition-window-difficulty = Difficulty:
|
||||||
@@ -18,12 +21,15 @@ salvage-expedition-window-next = Next offer
|
|||||||
# Expedition descriptions
|
# Expedition descriptions
|
||||||
salvage-expedition-desc-mining = Collect resources inside the area.
|
salvage-expedition-desc-mining = Collect resources inside the area.
|
||||||
# You will be taxed {$tax}% of the resources collected.
|
# You will be taxed {$tax}% of the resources collected.
|
||||||
salvage-expedition-desc-structure = Destroy {$count} {$structure} inside the area.
|
salvage-expedition-desc-structure = {$count ->
|
||||||
|
[one] Destroy {$count} {$structure} inside the area.
|
||||||
|
*[other] Destroy {$count} {$structure}s inside the area.
|
||||||
|
}
|
||||||
|
|
||||||
salvage-expedition-type-Mining = Mining
|
salvage-expedition-type-Mining = Mining
|
||||||
salvage-expedition-type-Destruction = Destruction
|
salvage-expedition-type-Destruction = Destruction
|
||||||
|
|
||||||
salvage-expedition-difficulty-None = Minimal
|
salvage-expedition-difficulty-Minimal = Minimal
|
||||||
salvage-expedition-difficulty-Minor = Minor
|
salvage-expedition-difficulty-Minor = Minor
|
||||||
salvage-expedition-difficulty-Moderate = Moderate
|
salvage-expedition-difficulty-Moderate = Moderate
|
||||||
salvage-expedition-difficulty-Hazardous = Hazardous
|
salvage-expedition-difficulty-Hazardous = Hazardous
|
||||||
@@ -33,3 +39,4 @@ salvage-expedition-difficulty-Extreme = Extreme
|
|||||||
salvage-expedition-announcement-countdown-minutes = {$duration} minutes remaining to complete the expedition.
|
salvage-expedition-announcement-countdown-minutes = {$duration} minutes remaining to complete the expedition.
|
||||||
salvage-expedition-announcement-countdown-seconds = {$duration} seconds remaining to complete the expedition.
|
salvage-expedition-announcement-countdown-seconds = {$duration} seconds remaining to complete the expedition.
|
||||||
salvage-expedition-announcement-dungeon = Dungeon is located {$direction}.
|
salvage-expedition-announcement-dungeon = Dungeon is located {$direction}.
|
||||||
|
salvage-expedition-completed = Expedition is completed.
|
||||||
|
|||||||
Reference in New Issue
Block a user