need help for 3d text label
#1

any idea for how can i make 3d txt label for all the players ( "Zombie" for the zombie team and "Human" for the human team)
Reply
#2

You can do a loop, or excepctions :B

example

pawn Код:
if (TeamZombie[playerid] == 1)
{
    Create3DTextLabel(...)
} else if (TeamHuman[playerid] == 2) {
    Create3dTextLabel(..)
}
Reply
#3

Quote:
Originally Posted by Lunnatiicz
Посмотреть сообщение
You can do a loop, or excepctions :B

example

pawn Код:
if (TeamZombie[playerid] == 1)
{
    Create3DTextLabel(...)
} else if (TeamHuman[playerid] == 2) {
    Create3dTextLabel(..)
}
ooo caus i was thinking that i must use something like that

Код:
for (new i = 0; i < MAX_PLAYERS; i++)
Reply
#4

Quote:
Originally Posted by Amine_Mejrhirrou
Посмотреть сообщение
ooo caus i was thinking that i must use something like that

Код:
for (new i = 0; i < MAX_PLAYERS; i++)
No you just can create and attach 3D Text at player spawn
And i suggest you to delete it on player death cos player can use F4 and it will bug a bit(multiple 3D Texts for one player)
Reply
#5

that's my script and i don't know why it's not working... any sugestion
Код:
new Text3D:label[MAX_PLAYERS];
Код:
public OnPlayerDisconnect(playerid, reason)
{
	Delete3DTextLabel(label[playerid]);
    return 1;
}
Код:
public OnPlayerSpawn(playerid)
{
	Delete3DTextLabel(label[playerid]);
	if(team[playerid] == 1)
	{
		label[playerid] = Create3DTextLabel("Human",0xAA3333AA, 0, 0, 0, 40, 0);
      	        Attach3DTextLabelToPlayer(label[playerid], playerid, 0.0, 0.0, 0.7);
		return 1;
	}
	if(team[playerid] == 2)
	{
		label[playerid] = Create3DTextLabel("Zombie",0xAA3333AA, 0, 0, 0, 40, 0);
      	        Attach3DTextLabelToPlayer(label[playerid], playerid, 0.0, 0.0, 0.7);
		return 1;
	}
	if(team[playerid] == 3)
	{
		label[playerid] = Create3DTextLabel("Zombie",0xAA3333AA, 0, 0, 0, 40, 0);
      	        Attach3DTextLabelToPlayer(label[playerid], playerid, 0.0, 0.0, 0.7);
		return 1;
	}
         return 1;
}
Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    Delete3DTextLabel(label[playerid]);
}
Reply
#6

update ...
guys pleas help
Reply
#7

sory for the again but pleas help me
" the problem is that the only one player has the tag" pleas help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)