02.04.2013, 21:22
Hi guys, I want to know how to do a Sync command pls help me.
Thanks
Thanks
ClearAnimations(playerid); TogglePlayerControllable(playerid,0); TogglePlayerControllable(playerid,1);
new PublicSync, Float:PublicArray[3];
CMD:sync(playerid) { GetPlayerPos(playerid, PublicArray[0], PublicArray[1], PublicArray[2]); PublicSync[playerid] = 1; SpawnPlayer(playerid); }
if(PublicSync[playerid]) { PublicSync[playerid] = 0; SetPlayerPos(playerid, PublicArray[0], PublicArray[1], PublicArray[2]); }
(17875) : error 028: invalid subscript (not an array or too many subscripts): "PublicSync" (17875) : warning 215: expression has no effect (17875) : error 001: expected token: ";", but found "]" (17875) : error 029: invalid expression, assumed zero (17875) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
if(PublicSync[playerid])