[Ajuda] Textdraw clicavel
#1

Alguem pode me ajudar?

to tentando criar uma td clicavel ai vai os cуdigo:

PHP код:
//topo
new Text:Textdraw14;
//OnGameModeInit
    
Textdraw14 TextDrawCreate(298.000000224.000000"Sair");
    
TextDrawBackgroundColor(Textdraw14255);
    
TextDrawFont(Textdraw142);
    
TextDrawLetterSize(Textdraw140.3400001.399999);
    
TextDrawColor(Textdraw14, -1);
    
TextDrawSetOutline(Textdraw141);
    
TextDrawSetProportional(Textdraw141);
    
TextDrawSetSelectable(Textdraw140);
//OnPlayerConnect
    
TextDrawShowForPlayer(playeridTextdraw14);
// OnPlayerClickTextDraw(playerid, Text:clickedid)
    
if(clickedid == Textdraw14)
    {
        
SendClientMessage(playerid0xFFFFFFAA"Textdraw14......");
      
    } 
Eu aperto la e nгo aconteзe nada
Reply
#2

PHP код:
    Textdraw14 TextDrawCreate(298.000000224.000000"Sair"); 
    
TextDrawBackgroundColor(Textdraw14255); 
    
TextDrawFont(Textdraw142); 
    
TextDrawLetterSize(Textdraw140.3400001.399999); 
    
TextDrawColor(Textdraw14, -1); 
    
TextDrawSetOutline(Textdraw141); 
    
TextDrawSetProportional(Textdraw141); 
PHP код:
TextDrawSetSelectable(playeridTextDraw:Textdraw14true); 
E isso tambem se for conectar na onplayerconnect..

PHP код:
SelectTextDraw(playerid0xFF0000FF); 
E isso para cancelar quando vocк clicar..

PHP код:
CancelSelectTextDraw(playerid); 
Reply
#3

Da uma olhada nisso aqui e saberб fazer certinho
https://sampforum.blast.hk/showthread.php?tid=340781
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)