Permalink
Browse files

Simplify the checks to make sure we are in space or instation before …

…proceeding...
  • Loading branch information...
1 parent b73fe07 commit d7b5ed45c49b4fd4a9ed5479d4046547b1cb61dd @ISeeDEDPpl committed May 10, 2012
Showing with 8 additions and 11 deletions.
  1. +8 −11 Questor/Questor.cs
View
@@ -301,20 +301,17 @@ private void OnFrame(object sender, EventArgs e)
_lastPulse = DateTime.Now;
// Session is not ready yet, do not continue
- if (!Cache.Instance.DirectEve.Session.IsReady)
- return;
-
- if (Cache.Instance.DirectEve.Session.IsReady)
- Cache.Instance.LastSessionIsReady = DateTime.Now;
-
- // We are not in space or station, don't do shit yet!
if (!Cache.Instance.InSpace && !Cache.Instance.InStation)
{
- Cache.Instance.NextInSpaceorInStation = DateTime.Now.AddSeconds(12);
- Cache.Instance.LastSessionChange = DateTime.Now;
- return;
+ Cache.Instance.NextInSpaceorInStation = DateTime.Now.AddSeconds(12);
+ Cache.Instance.LastSessionChange = DateTime.Now;
+ return;
}
-
+ else
+ {
+ Cache.Instance.LastSessionIsReady = DateTime.Now;
+ }
+
if (DateTime.Now < Cache.Instance.NextInSpaceorInStation)
return;

0 comments on commit d7b5ed4

Please sign in to comment.