hedgewars/uCommands.pas
changeset 7409 fd91aa100ce0
parent 7407 c1ade666c124
child 7412 9e5aa3c8dc62
--- a/hedgewars/uCommands.pas	Fri Jul 20 17:43:35 2012 -0400
+++ b/hedgewars/uCommands.pas	Fri Jul 20 18:48:04 2012 -0400
@@ -27,7 +27,7 @@
 
 procedure initModule;
 procedure freeModule;
-procedure RegisterVariable(Name: shortstring; p: TCommandHandler; Trusted: boolean; Synced: boolean);
+procedure RegisterVariable(Name: shortstring; p: TCommandHandler; Trusted: boolean; Rand: boolean);
 procedure RegisterVariable(Name: shortstring; p: TCommandHandler; Trusted: boolean);
 procedure ParseCommand(CmdStr: shortstring; TrustedSource: boolean);
 procedure ParseTeamCommand(s: shortstring);
@@ -41,7 +41,7 @@
         Next: PVariable;
         Name: string[15];
         Handler: TCommandHandler;
-        Trusted, Synced: boolean;
+        Trusted, Rand: boolean;
         end;
 
 var
@@ -51,7 +51,7 @@
 begin
 RegisterVariable(Name, p, Trusted, false);
 end;
-procedure RegisterVariable(Name: shortstring; p: TCommandHandler; Trusted: boolean; Synced: boolean);
+procedure RegisterVariable(Name: shortstring; p: TCommandHandler; Trusted: boolean; Rand: boolean);
 var
     value: PVariable;
 begin
@@ -61,7 +61,7 @@
 value^.Name:= Name;
 value^.Handler:= p;
 value^.Trusted:= Trusted;
-value^.Synced:= Synced;
+value^.Rand:= Rand;
 
 if Variables = nil then
     Variables:= value
@@ -93,7 +93,7 @@
     begin
     if t^.Name = CmdStr then
         begin
-        if t^.Synced then CheckSum:= CheckSum xor LongWord(SDLNet_Read32(@CmdStr)) xor LongWord(s[0]) xor GameTicks;
+        if t^.Rand then CheckSum:= CheckSum xor LongWord(SDLNet_Read32(@CmdStr)) xor LongWord(s[0]) xor GameTicks;
         if TrustedSource or t^.Trusted then
             t^.Handler(s);
         exit