How to convert this code?
#1

Hello SA-MP Users. My Doubt is:

I need an Admin Chat CMD like /a [Text]. Also a Vip chat with /v [Text]

Well, actually, my GM uses "#" for Admin Chat, and "*" For Vip Chat;

Here the Codes :
Код:
//==============================================================================
// Vip Chat
//==============================================================================
	if(text[0] == '*' && AccInfo[playerid][pVip] >= 1)
	{
	    new string[128]; GetPlayerName(playerid,string,sizeof(string));
		format(string,sizeof(string),"|ChatVip| %s: %s",string,text[1]);
		MessageToPlayerVIP(0xDC686BAA,string);
		SaveIn("ChatVipLog",string);
	    return 0;
	}
//==============================================================================
// Administration Chat
//==============================================================================
	if(text[0] == '#' && AccInfo[playerid][Level] >= 1)
	{
	    new string[128]; GetPlayerName(playerid,string,sizeof(string));
		format(string,sizeof(string),"Admin Chat: %s: %s",string,text[1]);
		MessageToAdmins(green,string);
		GetPlayerName(playerid,string,sizeof(string));
		format(string,sizeof(string),"9Admin Chat: %s: %s",string,text[1]);
		IRC_GroupSay(gGroupID2, IRC_ADMINCHANNEL, string);
		#if ADM_CHAT_LOG == true
		SaveIn("AdmChatLog",string);
		#endif
	    return 0;
	}
I disliked that, so i would appreciate to someone's help to convert those codes.

Thanks.
Reply


Messages In This Thread
How to convert this code? - by [WH]Marcos - 30.01.2013, 15:09
AW: How to convert this code? - by Blackazur - 30.01.2013, 15:10
Re: How to convert this code? - by Madeline - 30.01.2013, 15:13
Re: How to convert this code? - by tyler12 - 30.01.2013, 15:18
Re: How to convert this code? - by SKAzini - 30.01.2013, 15:20
Re: How to convert this code? - by [WH]Marcos - 30.01.2013, 15:23

Forum Jump:


Users browsing this thread: 2 Guest(s)