/group command help
#1

This is my group command:
Код:
CMD:group(playerid, params[]) {

	if(playerVariables[playerid][pStatus] != 1 || playerVariables[playerid][pGroup] < 1) return 1;
	if(groupVariables[playerVariables[playerid][pGroup]][gGroupType] == 1 || groupVariables[playerVariables[playerid][pGroup]][gGroupType] == 2) {
	    return SendClientMessage(playerid, COLOR_GREY, "This group does not have an OOC chat.");
	}
	new
	    string[128];

	if(isnull(params)) return SendClientMessage(playerid, COLOR_GREY, SYNTAX_MESSAGE"/g(roup) [message]");

	if(playerVariables[playerid][pFreezeType] > 0) {
		return SendClientMessage(playerid, COLOR_GREY, "You can't use this command while cuffed, tazed, or frozen.");
	}

 	GetPlayerName(playerid, szPlayerName, MAX_PLAYER_NAME);

	switch(playerVariables[playerid][pGroupRank]) {

		case 1:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName1], szPlayerName, params);
		case 2:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName2], szPlayerName, params);
		case 3:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName3], szPlayerName, params);
		case 4:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName4], szPlayerName, params);
		case 5:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName5], szPlayerName, params);
		case 6:	format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName6], szPlayerName, params);
		default: format(string, sizeof(string), "(Group Chat) %s %s: %s", groupVariables[playerVariables[playerid][pGroup]][gGroupRankName1], szPlayerName, params);
	}
    SendToGroup(playerVariables[playerid][pGroup], COLOR_DCHAT, string);
	return 1;
}
how do I make a group have a OOC Group chat?
Reply
#2

Copy paste the command, rename it, give it a different colour and add OOC brackets?
Reply
#3

dude are you for real? read what I said:
"how do I make a group have a OOC Group Chat?" It says that the group dosen't have a OOC chat.
Reply
#4

someone?
Reply
#5

Loop the groups variable into the command enabling them to use it.

Etc, IfGroupVariable [group1] into the command.
Reply
#6

dunno what you mean
Reply
#7

can someone help i urgently need this
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)