fix bug about failed missions
This commit is contained in:
parent
6d404a99e2
commit
69fddcaed6
@ -109,9 +109,9 @@ namespace EliteBGS.BGS {
|
|||||||
acceptedMissions[accepted.MissionID] = accepted;
|
acceptedMissions[accepted.MissionID] = accepted;
|
||||||
} else if (e.Is(Events.MissionFailed)) {
|
} else if (e.Is(Events.MissionFailed)) {
|
||||||
var failed = e as MissionFailedEntry;
|
var failed = e as MissionFailedEntry;
|
||||||
var accepted = acceptedMissions[failed.MissionID];
|
MissionAcceptedEntry accepted = null;
|
||||||
if (accepted == null) {
|
if (!acceptedMissions.TryGetValue(failed.MissionID, out accepted)) {
|
||||||
OnLog?.Invoke("Mission failed that wasn't accepted, please adjust time frame.");
|
OnLog?.Invoke("Mission failed that wasn't accepted in the given time frame, please adjust start date.");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
entry = new MissionFailed(accepted) { Failed = failed, System = current_system };
|
entry = new MissionFailed(accepted) { Failed = failed, System = current_system };
|
||||||
|
Loading…
Reference in New Issue
Block a user