// /ban [playerid]
if(strcmp(cmd, "/ban", true)==0)
{
if (adminlevel[playerid] == 0) return PlayerUsedAdminCommand(playerid);
new giveplayerid, reason[], uur, minuut, seconde;
GetTime(uur,minuut,seconde);
tmp = strtok(cmdtext, idx);
new BanS[128];
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_BASIC, "Gebruik: /ban [id] [reason]");
return 1; //Stopt het commando
}
giveplayerid = strval(tmp);
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_BASIC, "Gebruik: /ban [id] [reason]");
return 1; //Stopt het commando
}
reason[] = strval(tmp);
if(!IsPlayerConnected(giveplayerid))
{
SendClientMessage(playerid, COLOR_BASIC, "Speler is niet online"); return 1;
}
SendClientMessage(playerid, COLOR_BASIC, "Speler verband");
SendClientMessage(giveplayerid, COLOR_BASIC,"You are banned from the server!");
SendClientMessage(giveplayerid, COLOR_BASIC,"If you think you are banned for nothing");
SendClientMessage(giveplayerid, COLOR_BASIC,"Go to www.stuntland.tk and get CONTACT with the owner");
if (adminlevel[giveplayerid] == 2)
{
SendClientMessage(playerid, COLOR_BASIC, "Je kan niet iemand met een hoger level bannen");
} else {
format(BanS, sizeof(BanS), "you are banned by admin: %s, reason: %s, time: %s:%s:%s", playername, reason[], uur, minuut, seconde);
BanEx(giveplayerid,BanS);
}
return 1;
}
C:\Documents and Settings\Server\Bureaublad\StuntLand.pwn(1245) : error 009: invalid array size (negative, zero or out of bounds)
C:\Documents and Settings\Server\Bureaublad\StuntLand.pwn(1245) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Server\Bureaublad\StuntLand.pwn(1245) : error 017: undefined symbol "uur"
C:\Documents and Settings\Server\Bureaublad\StuntLand.pwn(1245) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
hoe te fixen?
Bewerkt: door Crusher!!