Minor tweaks to turn generator
1 files changed, 2 insertions(+), 4 deletions(-)

M turn.py
M turn.py +2 -4
@@ 110,8 110,6 @@ def make_turn(general, reginfo, commands
     for i in range(0, 11):
         if i+1 == general['player']:
             result += struct.pack('< i', checksum_x)
-        elif i+1 == 11: # Oddity when player isn't player 11
-            result += struct.pack('< i', int('0x0F31', 0))           
         else:
             result += struct.pack('< i', 0)
     return result

          
@@ 134,8 132,8 @@ def _get_winplan_trailer(turn, reginfo):
     # VPH35.DLL values (encoded similarly as in PCC v2's GTurnfile::setRegInfo)
     random.seed()
     vph1 = VPH_MAGIC[turn % len(VPH_MAGIC)]
-    vph2 = random.randint(0, 65535)
-    vph2 |= random.randint(0, 65535)
+    vph2 = random.randint(0, 2147483647)
+    vph2 |= random.randint(0, 2147483647)
     vph1 ^= vph2
     vph1 &= int('0x7FFFFFFF', 0)
     vph2 &= int('0x7FFFFFFF', 0)