Magic-constent elimination (use an enum instead.
[super-star-trek.git] / sst.h
diff --git a/sst.h b/sst.h
index c93fbc5deccba64d4934c4c3259879e204a8ca3a..5617ae3ce2b4964e4c55a6a1bb1a3963576ed4c8 100644 (file)
--- a/sst.h
+++ b/sst.h
 #define NEVENTS (8)\r
 \r
 typedef struct {\r
-       int x;  /* Quadrant location of planet */\r
-       int y;\r
-       int pclass; /* class M, N, or O (1, 2, or 3) */\r
-       int crystals; /* has crystals */\r
-       int known;   /* =1 contents known, =2 shuttle on this planet */\r
+    int x;     /* Quadrant location of planet */\r
+    int y;\r
+    int pclass; /* class M, N, or O (1, 2, or 3) */\r
+    int crystals; /* has crystals */\r
+    enum {unknown, known, shuttle_down} known;\r
 } planet;\r
 \r
 typedef struct {\r
@@ -54,7 +54,7 @@ typedef struct {
 // original names. Gee, I could have done this with the d structure,\r
 // but I just didn't think of it back when I started.\r
 \r
-EXTERN struct foo2 {\r
+EXTERN struct {\r
     snapshot state;\r
     snapshot snapsht;\r
     char quad[11][11];         // contents of our quadrant\r