PlayerTextDraws
#5

Quote:
Originally Posted by [HLF]Southclaw
Посмотреть сообщение
The array is a waste of time and memory!

There is no need for it if you pass a player ID to the PlayerTextDraw functions.

That's partly why PlayerTextDraws were created:

pawn Код:
// Old way
new Text:gStats[MAX_PLAYERS];
public OnPlayerConnect(playerid)
{
    gStats[playerid] = TextDrawCreate(...);
....


// New way
new PlayerText:gStats;
public OnPlayerConnect(playerid)
{
    gStats = CreatePlayerTextDraw([B]playerid[/B], ...);
....
I'll edit the wiki page to avoid confusion.
I disagree. I also, after reading this thread(https://sampforum.blast.hk/showthread.php?tid=336460), think the array thing is needed.
As I said before, somehow in my script Textdraws' Ids were mixed. I still don't understand how will array thing that prevent. i would say that using PlayerTextDraws is a very tricy thing.

Limit for PlayerTextDraw is 256 per player. Is this going over limits since MAX_PLAYERS=500?

new PlayerText:TextDraw[MAX_PLAYERS];
Reply


Messages In This Thread
PlayerTextDraws - by Roko_foko - 27.06.2012, 19:53
Re: PlayerTextDraws - by Roko_foko - 27.06.2012, 19:57
Re: PlayerTextDraws - by Vince - 27.06.2012, 20:01
Re: PlayerTextDraws - by Roko_foko - 27.06.2012, 20:10
Re: PlayerTextDraws - by Roko_foko - 27.06.2012, 21:31
Re: PlayerTextDraws - by Roko_foko - 27.06.2012, 21:36
Re: PlayerTextDraws - by vassilis - 27.06.2012, 21:53
Re: PlayerTextDraws - by vassilis - 27.06.2012, 22:16

Forum Jump:


Users browsing this thread: 1 Guest(s)