Improvements to the testing machinery, including the replay option.
[super-star-trek.git] / src / sst.h
index 2b30d8b17164457d370ee5db6ee39c591a517b8b..e9a805f5aaaaab0a1709169131a72b02a9e44176 100644 (file)
--- a/src/sst.h
+++ b/src/sst.h
@@ -178,6 +178,7 @@ extern int is_scheduled(int);
 extern event *schedule(int, double);
 extern void postpone(int, double);
 extern double scheduled(int);
+#define findevent(evtype)      &game.future[evtype]
 
 #define SSTMAGIC       "SST2.0\n"
 
@@ -204,6 +205,8 @@ struct game {
        ididit,         // action taken -- allows enemy to attack
        alive,          // we are alive (not killed)
        justin,         // just entered quadrant
+       shldup,         // shields are up
+       resting,        // rest time
        alldone,        // game is now finished
        neutz,          // Romulan Neutral Zone
        isarmed,        // probe is armed
@@ -254,7 +257,6 @@ struct game {
        indate,         // initial date
        energy,         // energy level
        shield,         // shield level
-       shldup,         // shields are up
        warpfac,        // warp speed
        wfacsq,         // squared warp factor
        lsupres,        // life support reserves
@@ -262,7 +264,6 @@ struct game {
        direc,          // movement direction
        optime,         // time taken by current operation
        docfac,         // repair factor when docking (constant?)
-       resting,        // rest time
        damfac,         // damage factor
        lastchart,      // time star chart was last updated
        cryprob,        // probability that crystal will work
@@ -281,9 +282,8 @@ extern double perdate;
 extern double aaitem;
 extern char citem[10];
 extern int seed;
-extern bool randready;
 extern bool idebug;
-extern FILE *logfp;
+extern FILE *logfp, *replayfp;
 
 /* the Space Thingy's global state should *not* be saved! */
 extern coord thing;