Text Draw help
#1

Hello guys i was making a new ATM system with textdraws in my server. every thing works fine except 2 things:

1: when that TextDraw comes, the arrow to select on of the option dont come.

2: there is a TextDaw with default string as NAMEHERE. i use TextDrawSetString when he uses commands /atm. but the string is not getting updated to his name and but, insted it just satys NAMEHERE.

please what am i doing wrong. here is the code of /atm.
PHP код:
CMD:atm(playeridparams[])
{
   new 
atmnamestring[65];
   if(
IsAtATM(playerid))
   {
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][0]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][1]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][2]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][3]);
    
format(atmnamestringsizeof(atmnamestring), "%s"GetPlayerNameEx(playerid));
    
TextDrawSetString(TDEditor_PTD[playerid][4], atmnamestring);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][4]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][5]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][6]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][7]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][8]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][9]);
    
PlayerTextDrawShow(playeridTDEditor_PTD[playerid][10]);
   
   }
   return 
1;

P.S. : i have not done anything in OnPlayerClickTextdraw so is that a prob? i just made that TD and just wanted to see if its showing or not. also, thanks to adri1's TDE Editor. thats great.
Reply
#2

try increasing size of the string atmnamestring to 128 or something.. may be it should work
Reply
#3

It's because it's not a textdraw but a player-textdraw
use PlayerTextDrawSetString

Quote:
Originally Posted by GTLS
Посмотреть сообщение
try increasing size of the string atmnamestring to 128 or something.. may be it should work
Stop suggesting people random BS, please.
Reply
#4

OMG i am so sorry, i didnt knew either about that Function. and btw i just did not suggesting him random solution, that worked for me once.. i had string size set as 28 so TextDraw was not updating but when i increased its size to 156, it worked but i dont remember that was a TextDraw or PlayerTextDraw but from your solution, i guess it was TextDraw..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)