SA-MP Forums Archive
Nick Names problems HELP NEEDED. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Nick Names problems HELP NEEDED. (/showthread.php?tid=365540)



Nick Names problems HELP NEEDED. - Mataaltedi - 03.08.2012

hello, I have a prolem with nick disapearing on my server, if i am onfoot and the other ppl is on foot too, so i can see their nicks, but if one of this ppl enter a car and then leave it his/her nick disapears, so if i want to see his/her nick i have to joi9n interior, like hospital or 24/7 and then leave from there... And i will see all the nick ... So i have tried ShowNameTags(1);
Some other things more difficult but nthing, the question is, there is a possibility to create some commands like

/nickRefresh SetPlayerNameTag(1)... Something like this... Or for example to /refreshnick and teleport player to interior and inmediatly set his/her position on the first position where was the command wrote... HELP...


Re: Nick Names problems HELP NEEDED. - Misiur - 03.08.2012

Check out DisableNameTagLOS, and ShowPlayerNameTagForPlayer


Respuesta: Nick Names problems HELP NEEDED. - Mataaltedi - 03.08.2012

Код HTML:
	if(newstate == PLAYER_STATE_ONFOOT)
	{
 		new giveplayer = GetClosestPlayer(playerid);
 		TogglePlayerControllable(playerid, 1);
	    if(GetDistanceBetweenPlayers(playerid,giveplayer) < 30)
		{
 			for(new i = 0; i < MAX_PLAYERS; i++)
    		{
    		    new toto1;
    		    new toto2;
				new nombre[MAX_PLAYER_NAME];
				new name2[MAX_PLAYER_NAME];
				toto1 = GetPlayerName(playerid, nombre, sizeof(nombre));
				toto2 = GetPlayerName(giveplayer, name2, sizeof(name2));
				if(PlayerInfo[playerid][pAdmin] >= 1)
				{
				    ShowPlayerNameTagForPlayer(i, playerid, 1);
				}
				if(BuddyInfo[playerid][Buddy1] == toto1 && BuddyInfo[giveplayer][Buddy2] == toto2)
				{
    	    		ShowPlayerNameTagForPlayer(giveplayer, playerid, 1);
    	    		ShowPlayerNameTagForPlayer(playerid, giveplayer,  1);
				}
				else
				{
				    ShowPlayerNameTagForPlayer(giveplayer, playerid, 0);
				    ShowPlayerNameTagForPlayer(playerid, giveplayer, 0);
				}
			}
		}
I have this and disablenametags i dont have nothing...