Posts: 362
Threads: 30
Joined: May 2012
Reputation:
0
Hi there, I'm wondering if it's possible to detect what textdraw the player clicks. Say you make a single box that can be used to heal and suicide, with heal having the heart object and suicide having the skull object as preview models. Is it possible to detect which ones the player is clicking? So it would heal you if you click heart, and kill you if you click the skull.
I appreciate the help.
Posts: 2,181
Threads: 98
Joined: Jan 2011
Reputation:
0
The clickedid in actually the textdraw id.
If you want two states, in the same textdraw just create a variable to store which state it is, and use this variable as a condition.
Posts: 11,827
Threads: 33
Joined: Dec 2011
Reputation:
0
The preview model has been in a specific textdraw. Check if its ID is the same as the textdraw ID the player clicked and do your code.
Posts: 2,181
Threads: 98
Joined: Jan 2011
Reputation:
0
Whenever you set that the text is a skull store it in a variable, then check about it later. Should be a global variable.
Posts: 362
Threads: 30
Joined: May 2012
Reputation:
0
Alright, thanks guys. I really appreciate it.