SA-MP Forums Archive
Text Draw String?? - 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: Text Draw String?? (/showthread.php?tid=274875)



Text Draw String?? - Tigerbeast11 - 07.08.2011

I want to create a text draw with a team kill counter... I am using this under OnPlayerDeath:

Код:
new tmpstr[50]; //Accommodate for string size
  	format(tmpstr,sizeof(tmpstr),"Grove: %d  Ballas:%d",GroveScore,BallasScore);
  	TextDrawSetString(scores,tmpstr);
Код:
new Text:scores
But I don't know how to use the TextDrawCreate function... I have the coordinates:
Код:
TextDrawCreate(350,400,"I don't know what to put here...")
Can someone please help me?


Re: Text Draw String?? - RyDeR` - 07.08.2011

You don't have to put anything in there since you reset the string with "TextDrawSetString". Just put that under OnGameMode/FilterScriptInit and you're done (don't forget to show the textdraw).


Re: Text Draw String?? - Tigerbeast11 - 07.08.2011

So I could just do this:
Код:
TextDrawCreate(350,400,"")



Re: Text Draw String?? - RyDeR` - 07.08.2011

No, that would crash the server. Use a space or underscore to keep it simple.


Re: Text Draw String?? - Tigerbeast11 - 07.08.2011

Oh, OK.