Cant Use Chat
#3

Quote:
Originally Posted by ForCop
Посмотреть сообщение
Код:
public OnPlayerText(playerid, text[])
{
    new string[144];
    //
     if(text[0] == '@' && Account[playerid][Admin] >= 1)
      {
           format(string, sizeof(string), "** |Admin Chat| %s: %s **", IsPlayerName(playerid), text[1]);
        for(new i = 0; i < MAX_PLAYERS; i++)
          {
            if(IsPlayerConnected(i) && Account[i][Admin] >= 1)
              {
              SendClientMessage(i, 0x0AFFC9FF, string);
              return 0;
            }
        }
    }
    if(text[0] == '!' && Account[playerid][Vip] >= 1)
    {
        format(string, sizeof(string), "~> |Vip Chat| %s: %s <~", IsPlayerName(playerid), text[1]);
         for(new i = 0; i < MAX_PLAYERS; i++)
           {
             if(IsPlayerConnected(i) && Account[i][Vip] >= 1)
               {
               SendClientMessage(i, 0xFF0099AA, string);
               return 0;
            }
        }
       }

         format(string, sizeof(string), "%s (%d): {FFFFFF}%s", IsPlayerName(playerid), playerid, text);
         SendClientMessageToAll(GetPlayerColor(playerid), string);

       return 1;
}
what?? can you please explain to me what is the error in my code rather than giving me a raw code that you write back from scratch, I want to learn .
Reply


Messages In This Thread
Cant Use Chat - by AfiqIqbal - 07.04.2018, 18:56
Re: Cant Use Chat - by ForCop - 07.04.2018, 19:23
Re: Cant Use Chat - by AfiqIqbal - 07.04.2018, 19:32
Re: Cant Use Chat - by ForCop - 07.04.2018, 19:39
Re: Cant Use Chat - by AdamsLT - 07.04.2018, 20:03
Re: Cant Use Chat - by AfiqIqbal - 08.04.2018, 03:23
Re: Cant Use Chat - by Mugala - 08.04.2018, 03:34
Re: Cant Use Chat - by Threshold - 08.04.2018, 03:41
Re: Cant Use Chat - by AfiqIqbal - 08.04.2018, 03:44
Re: Cant Use Chat - by Mugala - 08.04.2018, 03:50

Forum Jump:


Users browsing this thread: 1 Guest(s)