CreatePlayer3DTextLabel - Attach to player? -
FarTooBaked - 25.01.2016
I'm trying to use CreatePlayer3DTextLabel in the following way..
Players mobile rings,
Text label appears above his head changing colour [ALERT!] Mobile is ringing...
This will not work using global text draws as it would not efficiently work for 1000 players
Bearing in mind I'll use this sort of thing above landlines too for example but that is not a problem as I don't need
it to move with any players it'll be attached to an object.
Attach3DTextLabelToPlayer(Players3DText[playerid], playerid, X, Y, Z); <--- Does not work, tag mismatch
EDIT: Just thought actually... Can other players see the "CreatePlayer3DTextLabel" 's?
Re: CreatePlayer3DTextLabel - Attach to player? -
KillerDVX - 25.01.2016
Are you using a variable for checking if the phone's ringing ?
If yes, could you show me the definition of it ? That can helps to give you an exemple for your script.
Re: CreatePlayer3DTextLabel - Attach to player? -
FarTooBaked - 25.01.2016
Quote:
Originally Posted by KillerDVX
Are you using a variable for checking if the phone's ringing ?
If yes, could you show me the definition of it ? That can helps to give you an exemple for your script.
|
Here's an example of what I'm trying to do
pawn Код:
#new Player3DText:PlayerAlertMessage[MAX_PLAYERS];
pawn Код:
PlayerAlertMessage[playerid] = CreatePlayer3DTextLabel(playerid, "ALERT!", COLOR_RED, X, Y ,Z , 10.0);
pawn Код:
Attach3DTextLabelToPlayer(PlayerAlertMessage[playerid], playerid, 0, 0, 0);
This gives tag mismatch.
I do not want to use global 3d text for this.
Re: CreatePlayer3DTextLabel - Attach to player? -
KillerDVX - 25.01.2016
Try this bruuh.
PHP код:
Attach3DTextLabelToPlayer(PlayerAlertMessage[playerid], playerid, 0.0, 0.0, 0.3);
Re: CreatePlayer3DTextLabel - Attach to player? -
FarTooBaked - 25.01.2016
Quote:
Originally Posted by KillerDVX
Try this bruuh.
PHP код:
Attach3DTextLabelToPlayer(PlayerAlertMessage[playerid], playerid, 0.0, 0.0, 0.3);
|
Are you saying that making a simple adjustment to the Z coordinate makes all the difference? Or are you just guessing?
Re: CreatePlayer3DTextLabel - Attach to player? -
KillerDVX - 25.01.2016
It will make a difference, a simple try is free.
Re: CreatePlayer3DTextLabel - Attach to player? -
-CaRRoT - 25.01.2016
Replace
Код:
CreatePlayer3DTextLabel
with
Then +0.3 to the Z when you attach it.
https://sampwiki.blast.hk/wiki/CreatePlayer3DTextLabel
Description:
Creates a 3D Text Label
only for a specific player
Re: CreatePlayer3DTextLabel - Attach to player? -
FarTooBaked - 25.01.2016
Quote:
Originally Posted by -CaRRoT
|
This means I am using global 3d text and will limit me to 1000 max in the whole world? I need it to be per player?
EDIT: If 1500 things require some 3d text. Landlines ringing in the world... (by world I mean server) Mobiles ringing... Player alerts... I will only ever be able to do a maximum of 1000 of these?
Re: CreatePlayer3DTextLabel - Attach to player? -
-CaRRoT - 25.01.2016
Quote:
Originally Posted by FarTooBaked
This means I am using global 3d text and will limit me to 1000 max in the whole world? I need it to be per player?
|
Use the streamer for CreateDynamic3DTextLabel
Re: CreatePlayer3DTextLabel - Attach to player? -
FarTooBaked - 25.01.2016
Quote:
Originally Posted by -CaRRoT
Use the streamer for CreateDynamic3DTextLabel
|
EDIT: Thanks alot what a brain fart! Cheers buddy!