Selecting textdraw problem
#1

I'm trying to make a little close button for my textdraw. The X button should become white when selected.
But when I hover my mouse over the orange part that I drew, the X becomes white.
How do I only make the X clickable when the mouse is on it?



Код:
	XSign = TextDrawCreate(591.999877, 121.125930, "X");
	TextDrawTextSize(XSign, 574.999511, 574.999511);
	TextDrawLetterSize(XSign, 0.400000, 1.600000);
	TextDrawColor(XSign, 0xFF0000FF);
	TextDrawSetShadow(XSign, 0);
	TextDrawSetOutline(XSign, 0);
	TextDrawFont(XSign, 2);
	TextDrawSetSelectable(XSign, 1);
Reply
#2

You need to adjust the text size of the textdraw.
Here: https://sampwiki.blast.hk/wiki/TextDrawTextSize
Reply
#3

https://sampwiki.blast.hk/wiki/TextDrawSetSelectable
Quote:

Use TextDrawTextSize to define the clickable area.

https://sampwiki.blast.hk/wiki/TextDrawTextSize
Quote:

This function defines the clickable area for use with TextDrawSetSelectable, whether a box is shown or not.

Reply
#4

i cant figure out which X and Y to use
Reply
#5

PHP код:
TextDrawTextSize({textdraw name}, 261.5000000.000000); 
would be enough
Reply
#6

Quote:
Originally Posted by Sunehildeep
Посмотреть сообщение
PHP код:
TextDrawTextSize({textdraw name}, 261.5000000.000000); 
would be enough
Код:
TextDrawTextSize({textdraw name}, 261.500000, 0.000000);
Must not be 0
Reply
#7

Try this
PHP код:
TextDrawTextSize({textdraw name},391.00000,10.0000); 
This should work
Reply
#8

The X is not changing color anymore with any of these coordinates for some reason.
Reply
#9

Quote:
Originally Posted by PeanutButter
Посмотреть сообщение
The X is not changing color anymore with any of these coordinates for some reason.
What do you expect when you get help from some dude from India.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)