fix a bug with secondary objectives
This commit is contained in:
parent
dd9b558b3c
commit
e7a1656d2a
@ -146,25 +146,23 @@ namespace EliteBGS.BGS {
|
|||||||
"\" was generated, please report this.");
|
"\" was generated, please report this.");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (completed.Influences.Count > 1) {
|
foreach (var other in completed.Influences) {
|
||||||
foreach (var other in completed.Influences) {
|
string faction = other.Key;
|
||||||
string faction = other.Key;
|
if (string.IsNullOrEmpty(faction)) {
|
||||||
if (string.IsNullOrEmpty(faction)) {
|
continue;
|
||||||
continue;
|
}
|
||||||
}
|
foreach (var influences in other.Value) {
|
||||||
foreach (var influences in other.Value) {
|
ulong system_address = influences.Key;
|
||||||
ulong system_address = influences.Key;
|
if (!faction.Equals(results[0].Faction) ||
|
||||||
if (!faction.Equals(results[0].Faction) ||
|
(faction.Equals(results[0].Faction) && system_address != current_system_address)) {
|
||||||
(faction.Equals(results[0].Faction) && system_address != current_system_address)) {
|
string system = systems.TryGetValue(system_address, out string sys) ? sys : "";
|
||||||
string system = systems.TryGetValue(system_address, out string sys) ? sys : "";
|
results.Add(new InfluenceSupport() {
|
||||||
results.Add(new InfluenceSupport() {
|
Faction = faction,
|
||||||
Faction = faction,
|
Influence = influences.Value,
|
||||||
Influence = influences.Value,
|
System = system,
|
||||||
System = system,
|
SystemAddress = system_address,
|
||||||
SystemAddress = system_address,
|
RelevantMission = results[0] as MissionCompleted
|
||||||
RelevantMission = results[0] as MissionCompleted
|
});
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user