[HELP] Change Skin Command
#2

Change color?

See this anyway

Код:
//---------------------------------[SETSKIN]------------------------------------------------
	if(strcmp(cmd, "/setskin", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
			tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /setskin [playerid/PartOfName] [skin id]");
				return 1;
			}
			new para1;
			new level;
			para1 = ReturnUser(tmp);
			tmp = strtok(cmdtext, idx);
			level = strval(tmp);
			if(level > 299 || level < 1) { SendClientMessage(playerid, COLOR_GREY, "Wrong skin ID!"); return 1; }
			if (PlayerInfo[playerid][pAdmin] >= 3)
			{
			    if(IsPlayerConnected(para1))
			    {
			        if(para1 != INVALID_PLAYER_ID)
			        {
						GetPlayerName(para1, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						PlayerInfo[para1][pChar] = level;
						PlayerInfo[para1][pModel] = level;
						format(string, sizeof(string), "Your skin has been changed by Admin %s", sendername);
						SendClientMessage(para1, COLOR_WHITE, string);
						format(string, sizeof(string), "You have given %s skin to %d.", giveplayer,level);
						SendClientMessage(playerid, COLOR_WHITE, string);
					    SetPlayerSkin(para1, PlayerInfo[para1][pChar]);
					}
				}//not connected
			}
			else
			{
				SendClientMessage(playerid, COLOR_GRAD1, "   you are not authorized to use that command!");
			}
		}
		return 1;
	}
Reply


Messages In This Thread
[HELP] Change Skin Command - by DaRkAnGeL[NBK] - 13.10.2011, 19:06
Re: [HELP] Change Skin Command - by TheNavigator - 13.10.2011, 19:10
Re: [HELP] Change Skin Command - by SmiT - 13.10.2011, 19:12
Re: [HELP] Change Skin Command - by Azzeto - 13.10.2011, 19:12
Re: [HELP] Change Skin Command - by DaRkAnGeL[NBK] - 13.10.2011, 19:19
Re: [HELP] Change Skin Command - by DaRkAnGeL[NBK] - 13.10.2011, 19:23
AW: [HELP] Change Skin Command - by Tigerkiller - 13.10.2011, 19:40

Forum Jump:


Users browsing this thread: 1 Guest(s)