Quote:
Originally Posted by Pghpunkid
pawn Код:
forward SetPlayerClass(playerid, class[]); public SetPlayerClass(playerid, class[]) { new skin[32], asdf; SetPVarString(playerid, "Class", class); format(skin, 32, "TEAM_%s", class); asdf = "#skin"; }
Your problem (from what i can see) is that you are trying to assign "#skin" into a variable that is not compatible with strings. Try defining asdf as asdf[5].
Without more information thats all i can suggest.
|
No... I will create the function become :
pawn Код:
forward SetPlayerClass(playerid, class[]);
public SetPlayerClass(playerid, class[])
{
new skin[32], asdf;
SetPVarString(playerid, "Class", class);
format(skin, 32, "TEAM_%s", class);
asdf = "#skin";
SetPlayerSkin(playerid, asdf);
}
I mean when player spawned, the skin is become TEAM_(player class), so player skin will become skinid 2 if they are red team. But if I using
asdf[5] Im get an error :
Код:
error 035: argument type mismatch (argument 2)
Quote:
Originally Posted by nmader
May I ask what line it is on?
|
In a end of the line, at asdf = "#skin";
Sorry for my bad English