3D Text Label
#1

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?
Reply
#2

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;
Reply
#3

will that work?
Reply
#4

i think yes,,,
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)