[Ajuda] SetPlayerAttachedObject
#1

preciso de ajuda nesse cуdigo
Код:
SetPlayerAttachedObject(procuradoid, playerid, 19487, 2, 0.101, -0.0, 0.0, 5.50, 84.60, 83.7, 1, 1, 1, 0xFF00FF00);
preciso que ele mostre somente o objeto somente para a pessoa que usa o comando
Код:
UGB::TempoProcurar(playerid, procuradoid)
{
    if(!IsPlayerConnected(procuradoid))
	{
        KillTimer(TimerSS[playerid]);
		PlayerTextDrawHide(playerid, localidade[playerid]);
		DisablePlayerCheckpoint(playerid);
		return SendClientMessage(playerid, COLOR_LIGHTRED, "[INFO] O jogador que vocк estava procurando acaba de desconectar do servidor!");
    }
    new string[128];
    if(TempoProc[playerid] > 0)TempoProc[playerid] --;

    format(string, sizeof string, "_~n~~b~procurar ~h~~h~tempo~n~~w~%d", TempoProc[playerid]);
    GameTextForPlayer(playerid, string, 5000, 4);
	if(TempoProc[playerid] <= 0)
	{
		KillTimer(TimerSS[playerid]);
		PlayerTextDrawHide(playerid, localidade[playerid]);
		DisablePlayerCheckpoint(playerid);
		return 1;
	}

	new Float:x,Float:y,Float:z;
	GetPlayerPos(procuradoid, x, y, z);

	for(new i = 0; i != sizeof(gSAZones); i++)
	{
		if(x >= gSAZones[i][SAZONE_AREA][0] && x <= gSAZones[i][SAZONE_AREA][3] && y >= gSAZones[i][SAZONE_AREA][1] && y <= gSAZones[i][SAZONE_AREA][4])
		{
			if(GetPlayerInterior(procuradoid) > 0)
			{
			    format(string, sizeof string, "~y~Localizacao do ~r~~h~%s: ~w~~h~[Algum Interior]", NomePlayer(procuradoid));
			}
			else
				format(string, sizeof string, "~y~Localizacao do ~r~~h~%s: ~w~~h~[%s]", NomePlayer(procuradoid), gSAZones[i][SAZONE_NAME]);

			PlayerTextDrawSetString(playerid, localidade[playerid], string);
			PlayerTextDrawShow(playerid, localidade[playerid]);
			break;
		}
	}
	
	//SetPlayerCheckpoint(playerid, x +(random(10)-random(10)), y +(random(10)-random(10)), z, 5.0);
	SetPlayerAttachedObject(procuradoid, playerid, 19487, 2, 0.101, -0.0, 0.0, 5.50, 84.60, 83.7, 1, 1, 1, 0xFF00FF00);
	CP[playerid] = 597;
	return 1;
}
Reply
#2

pawn Код:
SetPlayerAttachedObject(playerid, 19487, 2, 0.101, -0.0, 0.0, 5.50, 84.60, 83.7, 1, 1, 1, 0xFF00FF00);
Reply
#3

nгo deu
Reply
#4

pawn Код:
SetPlayerAttachedObject(playerid, 2, 19487, 0.101, -0.0, 0.0, 5.50, 84.60, 83.7, 1, 1, 1, 0xFF00FF00);
Tenta agora e me diz se resulta.
Reply
#5

PHP код:
SetPlayerAttachedObject(playerid9194871,-0.4,-0.6,0.020.0,90.0,0.0); //objeto 
Reply
#6

ainda nгo deu, ele aparece pra todos do servidor
Reply
#7

Crie o objeto para o jogador que vocк quer que apareзa o objeto usando:
https://sampwiki.blast.hk/wiki/CreatePlayerObject

E depois anexe ele na skin do procurado usando:
https://sampwiki.blast.hk/wiki/AttachPlayerObjectToPlayer
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)