[Ajuda] Desabilitar Chat Global E Habilitar Um Prуximo
#1

Boa Tarde
Vamos As Dъvidas .

1- Como Hбbilito O Chat Global? Assim Que Se Diz? Chat Global Eu Digo, Vocк Escreve E Todo Mundo Ve.

2- Gostaria De Saber Como Fazer 1 Chat Prуximo


Por Exemplo:

Para Falar Com Quem Estб Perto:

/f Oi Amigo Vamos Para Balada? (Apareceu Sу Para Quem Estб Prуximo)
Reply
#2

pawn Код:
public OnPlayerText(playerid, text[]){     if(text[0] = ';' && text[1] = ' ')     {          new          Float:p[3],          string[128],          player[MAX_PLAYER_NAME];          GetPlayerName(playerid, player, sizeof(player));          GetPlayerPos(playerid, p[0], p[1], p[2]);          strdel(text, 0, 2);          format(string, sizeof(string), "%s: %d %s", player, playerid, text);          for(new i = 0; i < GetMaxPlayers(); i++)          {               if(IsPlayerConnected(i) && IsPlayerInRangeOfPoint(i, 25.0, p[0], p[1], p[2]))               {                    SendClientMessage(i, -1, string);               }          }          return false;     }     return true;}
Este Seria Para O Player Digitar E Aparecer Em Todo o Servidor ?
Reply
#3

Boa , Entendi , Muito Obrigado !

CASO ENCERRADO


+ REP
Reply
#4

Isso que o Mata_Noob, falou. Quando nгo for usado o /f na frente, logicamente serб o chat global. Ao menos que use algum GF ou GM, que jб seja bloqueado o uso do chat global.
Reply
#5

Logicamente ?

Meu Servidor Nгo Й Habilitado O Chat Global .
Reply
#6

Quando somente digita um texto, acontece o que ?
Reply
#7

//Chat Perto:
pawn Код:
public OnPlayerText(playerid, text[])
{
    static
        Float:Y,
        Float:X,
        Float:Z;
    GetPlayerPos(playerid, X, Y, Z);
    for(new i, e = GetMaxPlayers(); i != e; i++)
    {
        if(IsPlayerInRangeOfPoint(i, 100.0, X, Y, Z))
        {
            if(IsPlayerConnected(i))
            {
                SendClientMessage(i, -1, text);
            }
        }
    }
    return 1;
}

// Chat Global:
pawn Код:
if(!strcmp(cmdtext,"/E", true, 1))
{
    if(!cmdtext[3])
        return SendClientMessage(playerid, -1, "/e <texto>");
       
    new str[128];
    new Nom[24];
    GetPlayerName(playerid, Nom, 24);
    format(str, sizeof(str),"%s Diz: %s", Nome, cmdtext[3]);
    SendClientMessageToAll(-1, str);
    return 1;
}
Reply
#8

^^ caroline fez o q eu queria kkk'
vlew
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)