02.07.2016, 23:06
Код:
if(success) { SpamCheck[playerid] = GetTickCount(); } if(!success) return SendClientMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: Unknown command."); return 1;
if(success) { SpamCheck[playerid] = GetTickCount(); } if(!success) return SendClientMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: Unknown command."); return 1;
if(success)
{
SpamCheck[playerid] = GetTickCount();
return 1;
}
else {return SendClientMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: Unknown command."); }
if(success)
{
SpamCheck[playerid] = GetTickCount();
}
if(!success)
{
SendClientMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: Unknown command."); // no need to have "return" in front of this.
}
return 1;
Originally Posted by pawn-lang.pdf
225 unreachable code: The indicated code will never run, because an instruction before (above) it causes a jump out of the function, out of a loop or elsewhere. Look for return, break, continue and goto instructions above the indicated line. Unreachable code can also be caused by an endless loop above the indicated line.
|
if(success) SpamCheck[playerid] = GetTickCount(); else return SendClientMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: Unknown command.");