error 010: invalid function or declaration error 021: symbol already defined: "SendClientMessageEx" error 010: invalid function or declaration
new
RestartTime = 10,
RestartTimer,
str[512];
CMD:gmx(playerid)
{
if(PlayerInfo[playerid][pAdmin] < 99997) {
}
RestartTimer = SetTimer("ServerRestartTime",1000,true);
}
else
{
SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
}
return 1;
}
forward ServerRestartTime(playerid);
public ServerRestartTime(playerid)
{
RestartTime--;
if(RestartTime == 0)
{
KillTimer(RestartTimer);
RestartTime = 10;
SendRconCommand("gmx");
return 1;
}
format(str,sizeof(str),"~g~Server Restart: ~r~%d",RestartTime);
GameTextForAll(str,1150,3);
return 1;
}
|
this is a code I got from a filterscript and just wanted to add it to my script.. but keep getting these errors.
Код:
error 010: invalid function or declaration error 021: symbol already defined: "SendClientMessageEx" error 010: invalid function or declaration Код:
new
RestartTime = 10,
RestartTimer,
str[512];
CMD:gmx(playerid)
{
if(PlayerInfo[playerid][pAdmin] < 99997) {
}
RestartTimer = SetTimer("ServerRestartTime",1000,true);
}
else
{
SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
}
return 1;
}
forward ServerRestartTime(playerid);
public ServerRestartTime(playerid)
{
RestartTime--;
if(RestartTime == 0)
{
KillTimer(RestartTimer);
RestartTime = 10;
SendRconCommand("gmx");
return 1;
}
format(str,sizeof(str),"~g~Server Restart: ~r~%d",RestartTime);
GameTextForAll(str,1150,3);
return 1;
}
|
new
RestartTime = 10,
RestartTimer,
str[512];
CMD:gmx(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] < 99997)
{
RestartTimer = SetTimer("ServerRestartTime",1000,true);
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
}
return 1;
}
forward ServerRestartTime(playerid);
public ServerRestartTime(playerid)
{
RestartTime--;
if(RestartTime == 0)
{
KillTimer(RestartTimer);
RestartTime = 10;
SendRconCommand("gmx");
return 1;
}
format(str,sizeof(str),"~g~Server Restart: ~r~%d",RestartTime);
GameTextForAll(str,1150,3);
return 1;
}