mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-02-15 01:15:13 +01:00
fix NukeOpsTest (#3472)
This commit is contained in:
@@ -229,12 +229,18 @@ public sealed class NukeOpsTest
|
||||
var totalSeconds = 30;
|
||||
var totalTicks = (int) Math.Ceiling(totalSeconds / server.Timing.TickPeriod.TotalSeconds);
|
||||
var increment = 5;
|
||||
var resp = entMan.GetComponent<RespiratorComponent>(player);
|
||||
// Corvax-IPC-start
|
||||
var isIPC = entMan.GetComponent<MetaDataComponent>(player).EntityPrototype!.ID == "MobIpc" ? true : false;
|
||||
RespiratorComponent? resp = null;
|
||||
if (!isIPC)
|
||||
resp = entMan.GetComponent<RespiratorComponent>(player);
|
||||
// Corvax-IPC-end
|
||||
var damage = entMan.GetComponent<DamageableComponent>(player);
|
||||
for (var tick = 0; tick < totalTicks; tick += increment)
|
||||
{
|
||||
await pair.RunTicksSync(increment);
|
||||
Assert.That(resp.SuffocationCycles, Is.LessThanOrEqualTo(resp.SuffocationCycleThreshold));
|
||||
if (!isIPC) // Corvax-IPC
|
||||
Assert.That(resp!.SuffocationCycles, Is.LessThanOrEqualTo(resp.SuffocationCycleThreshold));
|
||||
Assert.That(damage.TotalDamage, Is.EqualTo(FixedPoint2.Zero));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user