textdraw bug
#1

hey, so can sameone help ?? ://

https://*********/FngfM9vi7oY

and then i press its dont work...

Код:
	if(_:clickedid != 65535)
	{
		if(clickedid == Ginklines[4][playerid])
		{
		    SendClientMessage(playerid, -1, "Paspaudei atgal");
	 	}
	 	else if(clickedid == Ginklines[5][playerid])
	 	{
	 	    SendClientMessage(playerid, -1, "Paspaudei toliau");
	  	}
	  	else if(clickedid == Ginklines[7][playerid])
	  	{
	  	    SendClientMessage(playerid, -1, "Paspaudei exita");
	  	    for(new s = 0; s < 10; s++) TextDrawHideForPlayer(playerid, Ginklines[playerid][s]);
	   	}
	   	else if(clickedid == Ginklines[6][playerid])
	   	{
	   	    SendClientMessage(playerid, -1, "Paspaudei pirkti");
	  	}
			CancelSelectTextDraw(playerid);
			for(new s = 0; s < 10; s++) TextDrawHideForPlayer(playerid, Ginklines[playerid][s]);
		}
		return 1;
Reply
#2

You need to use https://sampwiki.blast.hk/wiki/TextDrawTextSize to set the clickable area of the textdraws.
Reply
#3

Screw around a bit with TextDrawTextSize, or at least show us your textdraw code.
Reply
#4

Код:
Ginklines[p][4] = TextDrawCreate(198.500000, 344.750000, "atgal");
	TextDrawLetterSize(Ginklines[p][4], 0.345000, 1.665625);
	TextDrawAlignment(Ginklines[p][4], 1);
	TextDrawColor(Ginklines[p][4], -1);
	TextDrawSetShadow(Ginklines[p][4], 0);
	TextDrawSetOutline(Ginklines[p][4], 1);
	TextDrawBackgroundColor(Ginklines[p][4], 51);
	TextDrawFont(Ginklines[p][4], 2);
	TextDrawSetProportional(Ginklines[p][4], 1);
	TextDrawSetSelectable(Ginklines[p][4],true);

	Ginklines[p][5] = TextDrawCreate(395.000000, 344.750000, "toliau");
	TextDrawLetterSize(Ginklines[p][5], 0.322500, 1.687499);
	TextDrawAlignment(Ginklines[p][5], 1);
	TextDrawColor(Ginklines[p][5], -1);
	TextDrawSetShadow(Ginklines[p][5], 0);
	TextDrawSetOutline(Ginklines[p][5], 1);
	TextDrawBackgroundColor(Ginklines[p][5], 51);
	TextDrawFont(Ginklines[p][5], 2);
	TextDrawSetProportional(Ginklines[p][5], 1);
	TextDrawSetSelectable(Ginklines[p][5], true);
	
	Ginklines[p][6] = TextDrawCreate(299.500000, 365.750000, "pirkti");
	TextDrawLetterSize(Ginklines[p][6], 0.277500, 0.996250);
	TextDrawAlignment(Ginklines[p][6], 1);
	TextDrawColor(Ginklines[p][6], -1);
	TextDrawSetShadow(Ginklines[p][6], 0);
	TextDrawSetOutline(Ginklines[p][6], 1);
	TextDrawBackgroundColor(Ginklines[p][6], 51);
	TextDrawFont(Ginklines[p][6], 2);
	TextDrawSetProportional(Ginklines[p][6], 1);
	TextDrawSetSelectable(Ginklines[p][6],true);
	
	Ginklines[p][7] = TextDrawCreate(432.500000, 314.125000, "X");
	TextDrawLetterSize(Ginklines[p][7], 0.449999, 1.600000);
	TextDrawAlignment(Ginklines[p][7], 1);
	TextDrawColor(Ginklines[p][7], -1);
	TextDrawSetShadow(Ginklines[p][7], 0);
	TextDrawSetOutline(Ginklines[p][7], 1);
	TextDrawBackgroundColor(Ginklines[p][7], 51);
	TextDrawFont(Ginklines[p][7], 2);
	TextDrawSetProportional(Ginklines[p][7], 1);
	TextDrawSetSelectable(Ginklines[p][7],true);
Reply
#5

As I said, you didn't use the "TextDrawTextSize", so it didn't define the space of selection.

- KillerDVX.
Reply
#6

how to know what numbers write in TextDrawTextSize ?
Reply
#7

While you are having a "TextDrawTextSize", the Y size should be fine at 10 - 20.

- KillerDVX.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)