SA-MP Forums Archive
Textdraw problem - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Textdraw problem (/showthread.php?tid=620946)



Textdraw problem - StrikerZ - 05.11.2016

Hi i made some textdraws for event system. Like admin typed /event the textdraws will show up but here is the big g problem.
PHP код:
Textdraw15 TextDrawCreate(639.000000320.699981"usebox");
    
TextDrawLetterSize(Textdraw150.00000010.758892);
    
TextDrawTextSize(Textdraw15413.0000000.000000);
    
TextDrawAlignment(Textdraw151);
    
TextDrawColor(Textdraw150);
    
TextDrawUseBox(Textdraw15true);
    
TextDrawBoxColor(Textdraw15, -16382411);
    
TextDrawSetShadow(Textdraw150);
    
TextDrawSetOutline(Textdraw150);
    
TextDrawFont(Textdraw150);
    
Textdraw16 TextDrawCreate(639.000000300.540008"usebox");
    
TextDrawLetterSize(Textdraw160.0000001.861111);
    
TextDrawTextSize(Textdraw16413.0000000.000000);
    
TextDrawAlignment(Textdraw161);
    
TextDrawColor(Textdraw160);
    
TextDrawUseBox(Textdraw16true);
    
TextDrawBoxColor(Textdraw16, -16382209);
    
TextDrawSetShadow(Textdraw160);
    
TextDrawSetOutline(Textdraw160);
    
TextDrawFont(Textdraw160);
    
Textdraw17 TextDrawCreate(485.000000301.279998"EVENT INFO");
    
TextDrawLetterSize(Textdraw170.4499991.600000);
    
TextDrawAlignment(Textdraw171);
    
TextDrawColor(Textdraw17, -1);
    
TextDrawSetShadow(Textdraw170);
    
TextDrawSetOutline(Textdraw171);
    
TextDrawBackgroundColor(Textdraw1751);
    
TextDrawFont(Textdraw171);
    
TextDrawSetProportional(Textdraw171);
    
Textdraw18 TextDrawCreate(475.000000334.320007"");
    
TextDrawLetterSize(Textdraw180.4499991.600000);
    
TextDrawAlignment(Textdraw182);
    
TextDrawColor(Textdraw18, -1);
    
TextDrawSetShadow(Textdraw180);
    
TextDrawSetOutline(Textdraw181);
    
TextDrawBackgroundColor(Textdraw1851);
    
TextDrawFont(Textdraw181);
    
TextDrawSetProportional(Textdraw181); 
PHP код:
CMD:event(playeridparams[])
{
    if(
pInfo[playerid][pLevel] >= 5)
    {
        new 
info[120];
        if(
sscanf(params,"s[120]",info)) return SCM(playerid,COLOR_ORANGE,"USAGE: /event (information)");
        
TextDrawShowForAll(Textdraw15);
        
TextDrawShowForAll(Textdraw16);
        
TextDrawShowForAll(Textdraw17);
        
TextDrawShowForAll(Textdraw18);
         
TextDrawSetString(Textdraw18info);
    }
    return 
1;

The string should remain within the box but it gets out of the box. Isn't there anyway to make it stay within the box?


Re: Textdraw problem - oMa37 - 05.11.2016

Show the text before showing the box? I don't get what you mean actually ...


Re: Textdraw problem - StrikerZ - 05.11.2016

Lemme show you a screen shot


Re: Textdraw problem - StrikerZ - 05.11.2016

See if i type a long sentence that it will again not fill in. I found this on wiki https://sampwiki.blast.hk/wiki/TextDrawTextSize but i tried using them it also messes things up. Trying your's and will reply back


Re: Textdraw problem - StrikerZ - 05.11.2016

Your's was messed up, the text came up on the "Event info" text. And the same problem occured if we type a long text


Re: Textdraw problem - StrikerZ - 05.11.2016

Same problem. The text goes out of the box.


Re: Textdraw problem - StrikerZ - 05.11.2016

This what i'm expecting. The problem is this.




I need it to be like this.




{Not good in paint :P}


Re: Textdraw problem - StrikerZ - 05.11.2016

Try entering long sentences and you will get to know what i'm talking about


Re: Textdraw problem - StrikerZ - 05.11.2016

BUMP!


Re: Textdraw problem - StrikerZ - 05.11.2016

anyone?