Jump to content
  • 0

Problema Chat


d@rK

Question

Am pus un script ca sa scrie playerii in chat cu culoarea factiunii lor, dar cand cineva scrie ceva vede Tot serverul, si eu vreau sa se vada doar pe o raza mica.. cum e normal pe toate serverele.. nu stiu ce sa fac, ma puteti ajuta? :(

[pawn]

{

new  pName[MAX_PLAYER_NAME], String[150];

GetPlayerName(playerid, pName, sizeof(pName));

format(String, sizeof(String), "%s: {FFFFFF}%s", pName, text);

SendClientMessageToAll(GetPlayerColor(playerid), String);

return 0;

}[/pawn]

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

Atunci foloseste functia asta [pawn]stock SendRangedMessage(sourceid, color, message[], Float:range)

{

    new Float:x, Float:y, Float:z;

    GetPlayerPos(sourceid, x, y, z);

    for(new i = 0; i < MAX_PLAYERS; i++)

    {

        if(PlayerInfo[Logged] == 1)

        {

            if(GetPlayerVirtualWorld(sourceid) == GetPlayerVirtualWorld(i))

            {

                if(IsPlayerInRangeOfPoint(i, range, x, y, z))

                {

                    SendClientMessage(i, color, message);

                }

            }

        }

    }

    return 1;

}[/pawn]

SendRangedMessage(sourceid, color, message[], Float:range)

 

1859311972_BANNER-GIREADAcopy-min.thumb.png.48e5e420ae2185dce5b244965a1d2601.png

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.