Textdraw help
#1

Hello, i made this textdraw i put it OnGameModeInit so doesn't appear why?

On top
new Text:Welcome;

Quote:

Welcome = TextDrawCreate(7 ,459 , "XtremesServers.tk");
TextDrawFont(Welcome , 3);
TextDrawLetterSize(Welcome , 0.5, 3.5);
TextDrawColor(Welcome , 0xff4400FF);

And i wanna to know how to make a text appear when the player enter the server for 3 seconds the hide im trying with

Gametextforplayer i can't
Reply
#2

Now you have to show it
Put this:

Code:
public OnPlayerConnect(playerid)
{
    //This is used to show the player the textdraw when they connect.
    TextDrawShowForPlayer(playerid,Welcome);
}
Reply
#3

Yes of course it doesn't appear, because you have to show it manually using TextDrawShowForPlayer or TextDrawShowForAll.
If you already know that, then check that the text draw position is valid here
Code:
Welcome = TextDrawCreate(7 ,459 , "XtremesServers.tk");
Reply
#4

Dark_Rain

What do you mean?
Reply
#5

My post pretty much explained everything, Well what you did there is load textdraw, but you didn't actually show it, to show it you'd have to use one of those two function above of my post TextDrawShowForPlayer or TextDrawShowForAll
Example of code:
pawn Code:
public OnPlayerConnect(playerid)
{
//Your code bla bla
TextDrawShowForPlayer(playerid, Welcome);//This will show the text draw for the player when he connects
return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
//Your code bla bla
TextDrawHideForPlayer(playerid, Welcome);//This will hide the text draw for the player when he request class
return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)