Problem with helper chat HELP!!
#1

Well i was making a helper chat with /noht means when lead helper do /noht, all helper cant talk in/ht chat.
It works fine with the /noht but the thing is when the helperchat is enable only level 1 helper can chat in helperchat
Level 2 and three cant chat. i dont know why. I compile it well. Please check my mistake thank you
PHP код:
    if(strcmp(cmd"/helpt"true) == || strcmp(cmd"/ht"true) == 0)
    {
        if(
IsPlayerConnected(playerid))
        {
        if ((
noht))
        {
            
SendClientMessage(playeridCOLOR_GRAD2"   the helper chanel has been disabled by lead helper");
            return 
1;
        }
        if(
Mute[playerid] == 1)
            {
                
SendClientMessage(playeridTEAM_CYAN_COLOR"   You can't speak, you have been silenced !");
                return 
1;
            }
            
GetPlayerName(playeridsendernamesizeof(sendername));
            
GiveNameSpace(sendername);
            new 
length strlen(cmdtext);
            while ((
idx length) && (cmdtext[idx] <= ' '))
            {
                
idx++;
            }
            new 
offset idx;
            new 
result[128];
            while ((
idx length) && ((idx offset) < (sizeof(result) - 1)))
            {
                
result[idx offset] = cmdtext[idx];
                
idx++;
            }
            
result[idx offset] = EOS;
            if(!
strlen(result))
            {
                
SendClientMessage(playeridCOLOR_GRAD2"USAGE: (/h)elp(t) [helper chat chat]");
                return 
1;
            }
            
format(stringsizeof(string), "*** %s *** %s"PlayerInfo[playerid][pHelName], result);
            if (
PlayerInfo[playerid][pHelper] >= 1)
            {
            
SendHelperMessage(0x40808096string);
            }
            
//printf("Helper %s: %s", sendername, result);
        
}
        return 
1;
    }
    
    if(
strcmp(cmd"/noht"true) == 0)
    {
        if (
PlayerInfo[playerid][pHelper] >= && (!noht))
        {
            
noht 1;
            if(
stats)
            {
                
realchat 1;
            }
            
BroadCast(COLOR_GRAD2"   helper chat channel disabled by lead helper");
        }
        else if (
PlayerInfo[playerid][pAdmin] >= && (noht))
        {
            
noht 0;
            if(
stats)
            {
                
realchat 0;
            }
            
BroadCast(COLOR_GRAD2"   helper chat channel enabled by lead helper");
        }
        else
        {
            
SendClientMessage(playeridCOLOR_GRAD1"   you are not authorized to use that command!");
        }
        return 
1;
    } 
When i compile no errors only when ingame lead helper and level 2 helper cant chat i helperchat. Only level 1 helper can. WHy is that so?
I have added noht on top
new noht = 1;
Reply


Messages In This Thread
Problem with helper chat HELP!! - by jaami - 24.03.2012, 06:45
Re: Problem with helper chat HELP!! - by The__ - 24.03.2012, 07:41
Re: Problem with helper chat HELP!! - by jaami - 24.03.2012, 07:52
Re: Problem with helper chat HELP!! - by The__ - 24.03.2012, 07:54
Re: Problem with helper chat HELP!! - by jaami - 24.03.2012, 08:09
Re: Problem with helper chat HELP!! - by The__ - 24.03.2012, 08:19
Re: Problem with helper chat HELP!! - by jaami - 24.03.2012, 10:05

Forum Jump:


Users browsing this thread: 2 Guest(s)