]> git.pond.sub.org Git - empserver/commitdiff
Use int instead of signed char for pln_flags
authorMarkus Armbruster <armbru@pond.sub.org>
Sun, 13 Jan 2013 13:16:01 +0000 (14:16 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Wed, 8 May 2013 04:57:54 +0000 (06:57 +0200)
Just for consistency with other flags members.  Rearrange struct
plnstr to avoid holes.

include/plane.h
src/lib/common/nsc.c
tests/fairland/fairland.xdump
tests/files/files.xdump
tests/smoke/smoke.out
tests/smoke/smoke.xdump

index d6b29c028b594b19c3286c2aa63895dfcd89ecdf..b9ed2e9c361a571056f4d4bf2fad7967df541a33 100644 (file)
@@ -30,7 +30,7 @@
  *     Dave Pare, 1986
  *     Ken Stevens, 1995
  *     Steve McClure, 1998
- *     Markus Armbruster, 2004-2012
+ *     Markus Armbruster, 2004-2013
  */
 
 #ifndef PLANE_H
@@ -65,10 +65,10 @@ struct plnstr {
     short pln_radius;          /* mission radius */
     /* end of part matching struct empobj */
     unsigned char pln_range;   /* total distance, not radius */
+    signed char pln_harden;    /* for missiles */
     int pln_ship;              /* uid of carrier, or -1 */
     int pln_land;              /* uid of transporting land unit, or -1 */
-    signed char pln_harden;    /* for missiles */
-    signed char pln_flags;     /* State of the plane */
+    int pln_flags;             /* State of the plane */
     short pln_access;          /* Last tick mob was updated (MOB_ACCESS) */
     float pln_theta;           /* position in orbital sine wave */
 };
index 60268c88307e94ddad2911b4d5ddd20330c0a83f..a03d573f7876a53b6617cd5520267408a4de9d8b 100644 (file)
@@ -301,10 +301,10 @@ struct castr plane_ca[] = {
     NSC_GENITEM(EF_PLANE, EF_PLANE_CHR),
     {"wing", fldoff(pln_wing), NSC_STRINGY, 1, NULL, EF_BAD, 0},
     {"range", fldoff(pln_range), NSC_UCHAR, 0, NULL, EF_BAD, 0},
+    {"harden", fldoff(pln_harden), NSC_CHAR, 0, NULL, EF_BAD, 0},
     {"ship", fldoff(pln_ship), NSC_INT, 0, NULL, EF_SHIP, 0},
     {"land", fldoff(pln_land), NSC_INT, 0, NULL, EF_LAND, 0},
-    {"harden", fldoff(pln_harden), NSC_CHAR, 0, NULL, EF_BAD, 0},
-    {"flags", fldoff(pln_flags), NSC_CHAR, 0, NULL,
+    {"flags", fldoff(pln_flags), NSC_INT, 0, NULL,
      EF_PLANE_FLAGS, NSC_BITS},
     {"access", fldoff(pln_access), NSC_SHORT, 0, NULL, EF_BAD, 0},
     {"theta", fldoff(pln_theta), NSC_FLOAT, 0, NULL, EF_BAD, 0},
index 296023b73c9a5abc8095ae3396885380e08406ae..bf0461a3e5cae101c6c1665af2ab033657238843 100644 (file)
@@ -1029,7 +1029,7 @@ config ship
 uid owner xloc yloc type effic mobil off tech opx opy mission radius fleet xstart xend ystart yend cargostart(0) cargostart(1) cargostart(2) cargostart(3) cargostart(4) cargostart(5) cargoend(0) cargoend(1) cargoend(2) cargoend(3) cargoend(4) cargoend(5) amtstart(0) amtstart(1) amtstart(2) amtstart(3) amtstart(4) amtstart(5) amtend(0) amtend(1) amtend(2) amtend(3) amtend(4) amtend(5) autonav civil milit shell gun petrol iron dust bar food oil lcm hcm uw rad pstage ptime access mquota path follow name xbuilt ybuilt builder rflags rpath
 /config
 config plane
-uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range ship land harden flags access theta
+uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range harden ship land flags access theta
 /config
 config land
 uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship harden retreat rflags rpath civil milit shell gun petrol iron dust bar food oil lcm hcm uw rad pstage ptime land access
index d7734678a0b7111f28fd3d25fa545a3f3340e196..d33ca7b3a27b6c560553228aaabe931b30ffa679 100644 (file)
@@ -1029,7 +1029,7 @@ config ship
 uid owner xloc yloc type effic mobil off tech opx opy mission radius fleet xstart xend ystart yend cargostart(0) cargostart(1) cargostart(2) cargostart(3) cargostart(4) cargostart(5) cargoend(0) cargoend(1) cargoend(2) cargoend(3) cargoend(4) cargoend(5) amtstart(0) amtstart(1) amtstart(2) amtstart(3) amtstart(4) amtstart(5) amtend(0) amtend(1) amtend(2) amtend(3) amtend(4) amtend(5) autonav civil milit shell gun petrol iron dust bar food oil lcm hcm uw rad pstage ptime access mquota path follow name xbuilt ybuilt builder rflags rpath
 /config
 config plane
-uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range ship land harden flags access theta
+uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range harden ship land flags access theta
 /config
 config land
 uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship harden retreat rflags rpath civil milit shell gun petrol iron dust bar food oil lcm hcm uw rad pstage ptime land access
index 85ffbed0d201420dc86adecadbc0ae4d32ba788c..0dfa98b6ed6884984baae9c4f228ee1f3964396a 100644 (file)
@@ -153,10 +153,10 @@ Player 00 Turn 00 starting
 "radius" 6 0 0 -1
 "wing" 14 0 1 -1
 "range" 5 0 0 -1
+"harden" 4 0 0 -1
 "ship" 8 0 0 1
 "land" 8 0 0 3
-"harden" 4 0 0 -1
-"flags" 4 8 0 45
+"flags" 8 8 0 45
 "access" 6 0 0 -1
 "theta" 13 0 0 -1
 /21
@@ -1076,10 +1076,10 @@ CENSUS                   del dst
 "radius" 6 0 0 -1
 "wing" 14 0 1 -1
 "range" 5 0 0 -1
+"harden" 4 0 0 -1
 "ship" 8 0 0 1
 "land" 8 0 0 3
-"harden" 4 0 0 -1
-"flags" 4 8 0 45
+"flags" 8 8 0 45
 "access" 6 0 0 -1
 "theta" 13 0 0 -1
 /21
@@ -12758,9 +12758,9 @@ Player 00 Turn 99 starting
 /5
 
 [0:640] Command : XDUMP plane 0
-0 1 16 -14 0 89 90 0 51 0 0 0 0 "" 4 -1 -1 0 0 0 0.00000
-1 1 16 -14 0 92 91 0 51 0 0 0 0 "" 4 -1 -1 0 0 0 0.00000
-2 1 16 -14 0 93 102 0 51 16 -14 8 2 "" 4 -1 -1 0 0 0 0.00000
+0 1 16 -14 0 89 90 0 51 0 0 0 0 "" 4 0 -1 -1 0 0 0.00000
+1 1 16 -14 0 92 91 0 51 0 0 0 0 "" 4 0 -1 -1 0 0 0.00000
+2 1 16 -14 0 93 102 0 51 16 -14 8 2 "" 4 0 -1 -1 0 0 0.00000
 /3
 
 [0:640] Command : XDUMP land 0
@@ -13426,9 +13426,9 @@ You have a new telegram waiting ...
 /5
 
 [0:640] Command : XDUMP plane 0
-0 1 11 -1 0 89 90 0 51 -5 13 0 0 "" 4 -1 -1 0 0 0 0.00000
-1 1 11 -1 0 92 91 0 51 -5 13 0 0 "" 4 -1 -1 0 0 0 0.00000
-2 1 11 -1 0 93 102 0 51 11 -1 8 2 "" 4 -1 -1 0 0 0 0.00000
+0 1 11 -1 0 89 90 0 51 -5 13 0 0 "" 4 0 -1 -1 0 0 0.00000
+1 1 11 -1 0 92 91 0 51 -5 13 0 0 "" 4 0 -1 -1 0 0 0.00000
+2 1 11 -1 0 93 102 0 51 11 -1 8 2 "" 4 0 -1 -1 0 0 0.00000
 /3
 
 [0:640] Command : XDUMP land 0
index f35b9f3134e480b4616c330805af3b67a743c812..67cd2a322a3dd418983644094975da2a40a576ed 100644 (file)
@@ -1079,57 +1079,57 @@ uid owner xloc yloc type effic mobil off tech opx opy mission radius fleet xstar
 49 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 0 0 "" 0 "" 0 0 0 () ""
 /config
 config plane
-uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range ship land harden flags access theta
-0 1 16 -14 0 89 90 0 51 0 0 none 0 "" 4 -1 -1 0 () 0 0.00000
-1 1 16 -14 0 92 91 0 51 0 0 none 0 "" 4 -1 -1 0 () 0 0.00000
-2 1 16 -14 0 93 102 0 51 16 -14 offensive\040support 2 "" 4 -1 -1 0 () 0 0.00000
-3 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-4 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-5 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-6 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-7 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-8 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-9 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-10 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-11 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-12 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-13 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-14 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-15 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-16 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-17 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-18 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-19 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-20 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-21 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-22 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-23 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-24 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-25 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-26 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-27 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-28 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-29 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-30 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-31 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-32 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-33 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-34 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-35 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-36 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-37 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-38 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-39 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-40 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-41 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-42 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-43 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-44 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-45 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-46 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-47 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-48 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
-49 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 -1 -1 0 () 0 0.00000
+uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range harden ship land flags access theta
+0 1 16 -14 0 89 90 0 51 0 0 none 0 "" 4 0 -1 -1 () 0 0.00000
+1 1 16 -14 0 92 91 0 51 0 0 none 0 "" 4 0 -1 -1 () 0 0.00000
+2 1 16 -14 0 93 102 0 51 16 -14 offensive\040support 2 "" 4 0 -1 -1 () 0 0.00000
+3 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+4 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+5 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+6 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+7 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+8 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+9 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+10 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+11 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+12 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+13 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+14 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+15 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+16 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+17 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+18 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+19 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+20 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+21 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+22 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+23 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+24 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+25 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+26 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+27 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+28 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+29 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+30 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+31 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+32 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+33 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+34 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+35 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+36 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+37 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+38 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+39 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+40 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+41 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+42 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+43 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+44 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+45 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+46 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+47 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+48 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
+49 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000
 /config
 config land
 uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship harden retreat rflags rpath civil milit shell gun petrol iron dust bar food oil lcm hcm uw rad pstage ptime land access