Posts: 201
Threads: 19
Joined: Dec 2013
Hey guys,I want to make a command which can set the player's skin (by the whole player ,no admin staff)
How to make that using ZCMD? and where can i get it's last update?(the zcmd)
Posts: 201
Threads: 19
Joined: Dec 2013
Another small question:
I made a PlayerPlaySound when a player joins the server,how to stop it after the player spawn?
Posts: 3,133
Threads: 71
Joined: Dec 2013
Reputation:
0
You need to check if the skin is valid(0-311) or not or else it will set to CJ skin and or crash(it seems it sets to CJ instead of crashing in the RC versions -> haven't tested on the final release)
Posts: 201
Threads: 19
Joined: Dec 2013
Guys,ther eis some errors on that code,My fixed code :
pawn Код:
CMD:skin(playerid,params[])
{
new skinid;
if(sscanf(params,"i",skinid)) SendClientMessage(playerid,"Usage:/setskin [skinid]");
else if(skinid < 0 || skinid > 311) return SendClientMessage(playerid, -1, "Invalid skin!");
else SetPlayerSkin(playerid, skinid);
return 1;
}
And i fixed 4 errors,still got 2:
D:\Programmes\Engabic Blood Server\gamemodes\EABS.pwn(393) : error 017: undefined symbol "sscanf"
D:\Programmes\Engabic Blood Server\gamemodes\EABS.pwn(393) : error 035: argument type mismatch (argument 2)
Posts: 201
Threads: 19
Joined: Dec 2013
Now i have got the error 035:argument type mismatch on he same code above(that is the line
pawn Код:
if(sscanf(params,"i",skinid)) SendClientMessage(playerid,"Usage:/setskin [skinid]");