SA-MP Forums Archive
3D Text Label - 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: 3D Text Label (/showthread.php?tid=498726)



3D Text Label - Blackazur - 04.03.2014

Hello, i have this on OnPlayerSpawn:

Код:
	    SetPlayerHealth(playerid, 10000.0);
        SetTimerEx("EndAntiSpawnKill", 5000, false, "i", playerid);
        SendClientMessage(playerid, -1,""chat""COL_RED" Spawn Protection {FF0000}(5 Seconds)");
this the end anti spawnkill thing:

Код:
public EndAntiSpawnKill(playerid)
{
        SetPlayerHealth(playerid,100.0);
        SendClientMessage(playerid,-1,""chat" Spawn Protection Off");
    return 1;
}
My question now how can i add a 3d text label to that with "Spawn Protected" without that other players have it, that it dont delete after i delete it with "Delete3DTextLabel" etc?


Re: 3D Text Label - mahardika - 04.03.2014

at the top of script
pawn Код:
new Text3D:SpawnPText[MAX_PLAYERS];
onplayerspawn
pawn Код:
SetPlayerHealth(playerid, 10000.0);
SetTimerEx("EndAntiSpawnKill", 5000, false, "i", playerid);
SendClientMessage(playerid, -1,""chat""COL_RED" Spawn Protection {FF0000}(5 Seconds)");
SpawnPText[playerid] = CreateDynamic3DTextLabel( "Spawn Protected", 0xFF000000, 0.0, 0.0, 0.0, 10.0, playerid);//Creating the 3dtext
public EndAntiSpawnKill(playerid)
pawn Код:
DestroyDynamic3DTextLabel(SpawnPText[playerid]);//delete it
SetPlayerHealth(playerid,100.0);
SendClientMessage(playerid,-1,""chat" Spawn Protection Off");
return 1;



AW: 3D Text Label - Blackazur - 05.03.2014

will that work?


Re: 3D Text Label - mahardika - 05.03.2014

i think yes,,,