Texdraw Script Problem...
#1

Here is my script, it makes a box cover screen until the timer goes off again. Even thoe i tell it TextDrawHideForPlayer(i, red); it still won't make the red box go away...
Код:
public timer()
{
	new Text:red;
	red = TextDrawCreate(0,0," red");
	TextDrawFont(red,1);
	TextDrawLetterSize(red,1000,1000);
	TextDrawBoxColor(red,COLOR_RED);
	TextDrawUseBox(red,1);
      for(new i = 0; i < MAX_PLAYERS; i++)
	{
              if(blind[i] == 0)
	        {
                  TextDrawShowForPlayer(i, red);
			blind[i] = 1;
			SendClientMessage(i, COLOR_YELLOW, "blind = 1");
		  }
		  else
		  {
                   TextDrawHideForPlayer(i, red);
			blind[i] = 0;
			SendClientMessage(i, COLOR_YELLOW, "blind = 0");
		  }
      } 
       return 1;
}
Reply
#2

Known problem for SA-MP 0.2.2 R2 Clients. You have to destroy the textdraw instead of hiding it. It working on SA-MP 0.2.2 R3 though.
Reply
#3

It is true, if you Hide a textdraw and you are using the R2 Client, it dosn't always hide. Sometimes it does & sometimes it doesn't.
Reply
#4

Quote:
Originally Posted by Y_Leѕѕ
Not true at all. "red" is a local variable which means every time that function is called you are creating a NEW textdraw then hiding that one, instead of hiding the one the player can actually see.
so how would i fix it to do what i want?
Reply
#5

not post
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)