29.01.2013, 23:34
Quote:
Код:
CMD:jetpack(playerid, params[]) { new id, string[128], string2[128]; if(!IsPlayerAdmin(playerid)) return 0; { if(sscanf(params,"ii",id)) return SendClientMessage(playerid,COLOR_RED,"[ERROR]: /jetpack [playerID]"); else new nombre[MAX_PLAYER_NAME]; GetPlayerName(id, nombre, sizeof(nombre)); SetPlayerSpecialAction(id,SPECIAL_ACTION_USEJETPACK); format(string, sizeof(string),"Le diste a %s un jetpack!", nombre); SendClientMessage(playerid, COLOR_GREEN, string); format(string2 ,sizeof(string2),"%s te dio un jetpack!", id); SendClientMessage(id, COLOR_GREEN, string2); } return 1; } |
Код:
D:\Documents and Settings\Administrador\Mis documentos\Descargas\samp03x_svr_RC1_win32\filterscripts\carspawn.pwn(368) : error 003: declaration of a local variable must appear in a compound block D:\Documents and Settings\Administrador\Mis documentos\Descargas\samp03x_svr_RC1_win32\filterscripts\carspawn.pwn(368) : error 017: undefined symbol "nombre" D:\Documents and Settings\Administrador\Mis documentos\Descargas\samp03x_svr_RC1_win32\filterscripts\carspawn.pwn(368) : warning 215: expression has no effect D:\Documents and Settings\Administrador\Mis documentos\Descargas\samp03x_svr_RC1_win32\filterscripts\carspawn.pwn(368) : error 001: expected token: ";", but found "]" D:\Documents and Settings\Administrador\Mis documentos\Descargas\samp03x_svr_RC1_win32\filterscripts\carspawn.pwn(368) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
PHP код:
new nombre[MAX_PLAYER_NAME];