SA-MP Forums Archive
How to add textdraw - 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: How to add textdraw (/showthread.php?tid=153063)



How to add textdraw - MWF2 - 06.06.2010

How can i add this textdraw to my server?

I want it so, it only works when a player enters a certain checkpoint.

This is the checkpoint:
pawn Код:
if (gCheckpoint[18] == checkpointid) {
pawn Код:
Textdraw0 = TextDrawCreate(351.000000, 198.000000, "/buyheal - To Heal Yourself ($1000) /Buycure - To Cure Yourself ($4500) /healall - To heal/Cure Yourself ($5000)");
        TextDrawBackgroundColor(Textdraw0, 255);
        TextDrawFont(Textdraw0, 2);
        TextDrawLetterSize(Textdraw0, 0.360000, 1.500000);
        TextDrawColor(Textdraw0, 16777215);
        TextDrawSetOutline(Textdraw0, 0);
        TextDrawSetProportional(Textdraw0, 1);
        TextDrawSetShadow(Textdraw0, 1);
        TextDrawUseBox(Textdraw0, 1);
        TextDrawBoxColor(Textdraw0, 255);
        TextDrawTextSize(Textdraw0, 644.000000, 1377.000000);



Re: How to add textdraw - ViruZZzZ_ChiLLL - 06.06.2010

When he entered the checkpoint :
TextDrawShowForPlayer(playerid,td);

When he exits the checkpoint:
TextDrawHideForPlayer(playerid,td);


Re: How to add textdraw - MWF2 - 07.06.2010

But where do i put the whole textdraw code


Код:
		Textdraw0 = TextDrawCreate(351.000000, 198.000000, "/buyheal - To Heal Yourself ($1000) /Buycure - To Cure Yourself ($4500) /healall - To heal/Cure Yourself ($5000)");
		TextDrawBackgroundColor(Textdraw0, 255);
		TextDrawFont(Textdraw0, 2);
		TextDrawLetterSize(Textdraw0, 0.360000, 1.500000);
		TextDrawColor(Textdraw0, 16777215);
		TextDrawSetOutline(Textdraw0, 0);
		TextDrawSetProportional(Textdraw0, 1);
		TextDrawSetShadow(Textdraw0, 1);
		TextDrawUseBox(Textdraw0, 1);
		TextDrawBoxColor(Textdraw0, 255);
		TextDrawTextSize(Textdraw0, 644.000000, 1377.000000);



Re: How to add textdraw - ViruZZzZ_ChiLLL - 07.06.2010

Quote:
Originally Posted by MWF2
But where do i put the whole textdraw code


Код:
		Textdraw0 = TextDrawCreate(351.000000, 198.000000, "/buyheal - To Heal Yourself ($1000) /Buycure - To Cure Yourself ($4500) /healall - To heal/Cure Yourself ($5000)");
		TextDrawBackgroundColor(Textdraw0, 255);
		TextDrawFont(Textdraw0, 2);
		TextDrawLetterSize(Textdraw0, 0.360000, 1.500000);
		TextDrawColor(Textdraw0, 16777215);
		TextDrawSetOutline(Textdraw0, 0);
		TextDrawSetProportional(Textdraw0, 1);
		TextDrawSetShadow(Textdraw0, 1);
		TextDrawUseBox(Textdraw0, 1);
		TextDrawBoxColor(Textdraw0, 255);
		TextDrawTextSize(Textdraw0, 644.000000, 1377.000000);
Under :
pawn Код:
public OnGameModeInit()
{
 return 1;
}



Re: How to add textdraw - MWF2 - 07.06.2010

Ok, I did that. Now, Every time i spawn the textdraw is shown....I have no idea why and it doesnt go away at all


Re: How to add textdraw - MWF2 - 08.06.2010

anyone?