SA-MP Forums Archive
Create3DTextLabel & Attatch3DTextLabelToPlayer problems - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Create3DTextLabel & Attatch3DTextLabelToPlayer problems (/showthread.php?tid=119348)



Create3DTextLabel & Attatch3DTextLabelToPlayer problems - _Vortex - 07.01.2010

Hey, I'm trying to make it create and attatch a 3D text label to a player if they're admin when they spawn.

Here's my code:
Код:
public OnPlayerSpawn(playerid)
{
	if(Jailed[playerid]) return SetPlayerPos(playerid,2194.044921875, -7526.716796875, 2537.0349121094);
	if(pInfo[playerid][Level] > 0) {
	label = Create3DTextLabel("Admin",COLOR_RED,0.0,0.0,0.0,40.0,0); // tag mismatch
  Attach3DTextLabelToPlayer(label,playerid,0.0,0.0,0.0); // tag mismatch
  return 1;
  }
	return 1;
}
I'm getting "tag mismatch" on both the Create3DTextLabel and Attach3DTextLabelToPlayer lines

I have no experience with 3D text labels, i've done what the wiki said, still no luck.


Re: Create3DTextLabel & Attatch3DTextLabelToPlayer problems - John Rockie - 07.01.2010

I trying to script that too


Re: Create3DTextLabel & Attatch3DTextLabelToPlayer problems - PotH3Ad - 07.01.2010

On the top of the script:

Код:
new Text3D:label[MAX_PLAYERS];
Код:
public OnPlayerSpawn(playerid)
{
	if(Jailed[playerid]) return SetPlayerPos(playerid,2194.044921875, -7526.716796875, 2537.0349121094);
	if(pInfo[playerid][Level] > 0) {
	label[playerid] = Create3DTextLabel("Admin",COLOR_RED,0,0,0,40,0);
	Attach3DTextLabelToPlayer(label[playerid],playerid,0.0,0.0,0.0);
  	return 1;
  }
	return 1;
}



Re: Create3DTextLabel & Attatch3DTextLabelToPlayer problems - _Vortex - 07.01.2010

Quote:
Originally Posted by edgar_macias
On the top of the script:

Код:
new Text3D:label[MAX_PLAYERS];
Код:
public OnPlayerSpawn(playerid)
{
	if(Jailed[playerid]) return SetPlayerPos(playerid,2194.044921875, -7526.716796875, 2537.0349121094);
	if(pInfo[playerid][Level] > 0) {
	label[playerid] = Create3DTextLabel("Admin",COLOR_RED,0,0,0,40,0);
	Attach3DTextLabelToPlayer(label[playerid],playerid,0.0,0.0,0.0);
  	return 1;
  }
	return 1;
}
Thank you