04.08.2011, 20:20
True, but I got some errors!
Also, can anybody gimme jail-co-ordinates?
Код:
D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(94) : error 017: undefined symbol "x" D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(95) : error 017: undefined symbol "JailTimer" D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(95) : warning 215: expression has no effect D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(95) : error 001: expected token: ";", but found "]" D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(95) : error 029: invalid expression, assumed zero D:\Program Files\Rockstar Games\GTA San Andreas\eigener SAMP\gamemodes\deathmatch.pwn(95) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 5 Errors.
pawn Код:
CMD:jail(playerid, params[])
{
new id, mins, str[128];
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xffffffff, "You're not Admin!");
if(sscanf(params, "ud", id, mins)) return SendClientMessage(playerid, 0xffffffff, "[Usage]: /jail <id> <minutes>");
if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, 0xffffffff, "Invalid player id.");
SetPlayerPos(id, x, y, z); //ERROR, NEED JAILPOS
JailTimer[id] = SetTimerEx("Unjail", mins*60*1000, 0, "d", id); //ERROR
format(str, sizeof(str), "You jailed %s for %d mins.", GetName(id), mins);
SendClientMessage(playerid, 0xffffffff, str);
format(str, sizeof(str), "%s jailed you for %d mins.", GetName(playerid), mins);
SendClientMessage(id, 0xffffffff, str);
return 1;
}