mainmenu7 = TextDrawCreate( 92.062500, 340.375000, "Race!"); TextDrawLetterSize( mainmenu7 , 0.340997, 1.114374); TextDrawTextSize( mainmenu7 , 199.000000, -6.562500); TextDrawAlignment( mainmenu7 , 1); TextDrawColor( mainmenu7 , -1); TextDrawUseBox( mainmenu7 , true); TextDrawBoxColor( mainmenu7 , -16777179); TextDrawSetShadow( mainmenu7 , 0); TextDrawSetOutline( mainmenu7 , 1); TextDrawBackgroundColor( mainmenu7 , 51); TextDrawFont( mainmenu7 , 1); TextDrawSetProportional( mainmenu7 , 1); TextDrawSetSelectable( mainmenu7 , true);
The clickable area is defined by TextDrawTextSize. The x and y parameters passed to that function must not be zero or negative. |
mainmenu13 = TextDrawCreate( 582.500000, 387.812500, "broadcast"); TextDrawLetterSize( mainmenu13 , 0.000000, 1.586109); TextDrawTextSize( mainmenu13 , 467.500000, 20.000000); TextDrawAlignment( mainmenu13 , 1); TextDrawColor( mainmenu13 , 0); TextDrawUseBox( mainmenu13 , true); TextDrawBoxColor( mainmenu13 , 0); TextDrawSetShadow( mainmenu13 , 0); TextDrawSetOutline( mainmenu13 , 0); TextDrawFont( mainmenu13 , 0); TextDrawSetSelectable( mainmenu13 , true);
By the way - possible is call SelectTextDraw by click ESC? I want to make it unable to disable. |
By the way - possible is call SelectTextDraw by click ESC? I want to make it unable to disable. |
if(clickedid == Text:INVALID_TEXT_DRAW) { //player clicked ESC, here you can use SelectTextDraw again }
TextDrawLetterSize also must be positive, more than 0.0 - I recommend iTD script to textdraws if you have problem with clickable area.
Yes, this is possible. Callback OnPlayerClickTextDraw is called when you click ESC with clicked value INVALID_TEXT_DRAW, so Код:
if(clickedid == Text:INVALID_TEXT_DRAW) { //player clicked ESC, here you can use SelectTextDraw again } |
TextDrawTextSize( mainmenu13 , 40.500000, 50.000000);
SelectTextDraw(playerid, COLOR);
mainmenu13 = TextDrawCreate( 582.500000, 387.812500, "broadcast"); TextDrawLetterSize( mainmenu13 , 0.000000, 1.586109); TextDrawTextSize( mainmenu13 , 467.500000, 20.000000); TextDrawAlignment( mainmenu13 , 1); TextDrawColor( mainmenu13 , 0); TextDrawUseBox( mainmenu13 , true); TextDrawBoxColor( mainmenu13 , 0); TextDrawSetShadow( mainmenu13 , 0); TextDrawSetOutline( mainmenu13 , 0); TextDrawFont( mainmenu13 , 0); TextDrawSetSelectable( mainmenu13 , true);