Show name with sniper
#1

Hallo,

I want that if a player looks through the visor of a sniper, the names of the other players are displayed. I tried it just as it is not somehow

pawn Код:
if(GetPlayerWeapon(playerid) == 34 && !IsPlayerInAnyVehicle(playerid))
        {
            new PlayerText3D:snipertext[MAX_PLAYERS];
            if(PRESSED(KEY_HANDBRAKE))
                {
                    for(new i; i<MAX_PLAYERS;i++)
                        {
                            if(IsPlayerConnected(i))
                                {
                                            new Float:X, Float:Y, Float:Z;
                                            GetPlayerPos(i, X, Y, Z);
                                            new string[128];
                                            format(string,sizeof(string),"%s",PName[i]);
                                            snipertext[i] = CreatePlayer3DTextLabel(playerid,string,0x008080FF,X,Y,Z+1,315.0,i);
                                }
                        }
                }
            else if(RELEASED(KEY_HANDBRAKE))
                {
                    for(new i; i<MAX_PLAYERS;i++)
                        {
                            DeletePlayer3DTextLabel(playerid,snipertext[i]);
                        }
                }
        }
Reply


Messages In This Thread
Show name with sniper - by deathrunner - 28.07.2013, 11:23
Re: Show name with sniper - by NotIntegrated - 28.07.2013, 11:28
Re: Show name with sniper - by deathrunner - 28.07.2013, 11:34
Re: Show name with sniper - by deathrunner - 28.07.2013, 12:16

Forum Jump:


Users browsing this thread: 1 Guest(s)