21.06.2012, 11:28
Hello,
I got 4 Errors with compiling this.
Its if a player goes offline to avoid prison, then he can still get prisoned but, I want to show his prisons in stats so it has to count 1 on it.
Anyone help?
I got 4 Errors with compiling this.
pawn Код:
C:\Users\Stefan Dorst\Desktop\Volcom Rp\gamemodes\SRP.pwn(13984) : error 029: invalid expression, assumed zero
C:\Users\Stefan Dorst\Desktop\Volcom Rp\gamemodes\SRP.pwn(13984) : warning 215: expression has no effect
C:\Users\Stefan Dorst\Desktop\Volcom Rp\gamemodes\SRP.pwn(13984) : error 001: expected token: ";", but found ")"
C:\Users\Stefan Dorst\Desktop\Volcom Rp\gamemodes\SRP.pwn(13984) : error 029: invalid expression, assumed zero
C:\Users\Stefan Dorst\Desktop\Volcom Rp\gamemodes\SRP.pwn(13984) : 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.
pawn Код:
command(oprison, playerid, params[])
{
new Name[128], string[128], time, Reason[128];
if(sscanf(params, "zdz", Name, time, Reason))
{
if(Player[playerid][AdminLevel] >= 1 || Player[playerid][Moderator] >= 1)
{
SendClientMessage(playerid, WHITE, "SYNTAX: /oprison [name] [time] [reason]");
SendClientMessage(playerid, GREY, "NOTE: This command is CaSe SeNsItIvE.");
}
}
else
{
if(Player[playerid][AdminLevel] >= 1 || Player[playerid][Moderator] >= 1)
{
if(strlen(Name) >= 3 && strlen(Name) < MAX_PLAYER_NAME+1)
{
format(string, sizeof(string), "Accounts/%s.ini", Name);
if(fexist(string))
{
dini_IntSet(string, "PrisonDuration", time*60);
dini_IntSet(string, "PrisonID", 1);
dini_IntSet(string, "Muted", 1);
dini_IntSet(string, "APrisons", +1);
dini_Set(string, "Note", Reason);
format(string, sizeof(string), "Prison: %s has been prisoned by %s, reason: %s (%d minutes).", Name, GetName(playerid), Reason, time);
SendClientMessageToAll(RED, string);
format(string, sizeof(string), "%s has offine prisoned %s", GetName(playerid), Name);
SendToAdmins(ADMINORANGE, string, 0);
}
else
{
SendClientMessage(playerid, WHITE, "Account not found.");
}
}
}
}
}
Anyone help?