27.01.2012, 16:36
pawn Код:
new
p_State[MAX_PLAYERS char] = -1;
pawn Код:
stock GetPlayerScriptState(playerid)
{
new
p_StateName[32];
switch(p_State{playerid})
{
case -2: { return p_StateName = "Class Selection"; }
case -1: { return p_StateName = "Not Spawned"; }
case 0: { return p_StateName = "Spectating"; }
case 1: { return p_StateName = "Spawned"; }
case 2: { return p_StateName = "Dead"; }
}
return p_StateName;
}
Quote:
terror.pwn(204) : error 079: inconsistent return types (array & non-array) terror.pwn(205) : error 079: inconsistent return types (array & non-array) terror.pwn(206) : error 079: inconsistent return types (array & non-array) terror.pwn(207) : error 079: inconsistent return types (array & non-array) terror.pwn(20 : error 079: inconsistent return types (array & non-array) |
EDIT: I'm an idiot. You can't return and expect it to return a value later on. Duh. Close this!