How to detect if player didn't select any textdraw.
#1

I know about OnPlayerClickPlayerTextDraw but what if player press `Esc` and cancel the selection ?

Is there any callback like OnPlayerCancelPlayerTextDraw ?
Reply
#2

PHP Code:
public OnPlayerClickTextDraw(playeridText:clickedid)
{
  if(
clickedid == Text:INVALID_TEXT_DRAW)
  {
        
// your code
  
}
  return 
1;

And if you use OnPlayerClickPlayerTextDraw you detect ESC with OnPlayerClickTextDraw.

ps: never use CancelSelectTextDraw when the player ESC on select textdraw.
Reply
#3

Quote:
Originally Posted by ******
View Post
Have you thought about trying to read the documentation on the wiki?

https://sampwiki.blast.hk/wiki/OnPlayerClickTextDraw
OnPlayerClickPlayerTextDraw is NOT called when selection is cancelled.
However OnPlayerClickTextDraw works fine.
And no. I won't bother to read that ugly SA:MP wiki while I can simply ask here so someone else can provide me the solution.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)