18.03.2011, 09:44
hey guys .
So,I need the GetPlayerID function . so I added it in the end of the GM.(stock)
like this
yep, not i got the errors.
line 3185
for(new i = 0; new max = GetMaxPlayers(); i < max; i++)
So,I need the GetPlayerID function . so I added it in the end of the GM.(stock)
like this
Код:
stock GetPlayerID(const Name[]) { for(new i = 0; new max = GetMaxPlayers(); i < max; i++) { if(IsPlayerConnected(i)) { new pName2[MAX_PLAYER_NAME]; GetPlayerName(i, pName2, sizeof(pName2)); if(strcmp(Name, pName2, true) ==0) { return i; } } } return -1; }
PHP код:
(3185) : error 029: invalid expression, assumed zero
(3185) : warning 204: symbol is assigned a value that is never used: "i"
(3185) : error 017: undefined symbol "i"
(3185) : error 076: syntax error in the expression, or invalid function call
(3185) : fatal error 107: too many error messages on one line
for(new i = 0; new max = GetMaxPlayers(); i < max; i++)