v0.10.5.1
This commit is contained in:
@@ -34,6 +34,8 @@ namespace Barotrauma
|
||||
|
||||
private bool WereAllTargetsInfected()
|
||||
{
|
||||
if (targetWasInfected == null) { return false; }
|
||||
|
||||
for (int i = 0; i < targetWasInfected.Length; i++)
|
||||
{
|
||||
if (targetWasInfected[i]) continue;
|
||||
@@ -52,8 +54,12 @@ namespace Barotrauma
|
||||
poisonName = TextManager.FormatServerMessage(poisonId) ?? poisonId;
|
||||
|
||||
Targets = traitor.Mission.FindKillTarget(traitor.Character, Filter, targetCount, targetPercentage);
|
||||
if (Targets == null)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
targetWasInfected = new bool[Targets.Count];
|
||||
return Targets != null && !Targets.All(t => t.IsDead);
|
||||
return !Targets.All(t => t.IsDead);
|
||||
}
|
||||
|
||||
public GoalInjectTarget(TraitorMission.CharacterFilter filter, string poisonId, string afflictionId, int targetCount, float targetPercentage) : base()
|
||||
|
||||
@@ -137,6 +137,10 @@ namespace Barotrauma
|
||||
startCountdown = MathHelper.Lerp(server.ServerSettings.TraitorsMinRestartDelay, server.ServerSettings.TraitorsMaxRestartDelay, (float)RandomDouble());
|
||||
return;
|
||||
}
|
||||
if (Character.CharacterList.Count(c => !c.IsDead && c.TeamID == Character.TeamType.Team1 || c.TeamID == Character.TeamType.Team2) <= 1)
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (GameMain.GameSession.Mission is CombatMission)
|
||||
{
|
||||
var teamIds = new[] { Character.TeamType.Team1, Character.TeamType.Team2 };
|
||||
|
||||
Reference in New Issue
Block a user