[Ajuda] TEXTDRAW BUGADO
#20

PHP Code:
//  Topo do GM
new PlayerText:Rodape[MAX_PLAYERS][7];
forward RodapeTD(playerid);
//  Public OnPlayerConnect
public OnPlayerConnect(playerid)
{
    
LoadTextDraws(playerid);
    return 
1;
}
//  Final do GM
LoadTextDraws(playerid)
{
    
SetTimerEx("RodapeTD", 500, true, "d", playerid);
    
Rodape[playerid][0] = CreatePlayerTextDraw(playerid, 641.529418, 423.250000, "_");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][0], 255);
    
PlayerTextDrawFont(playerid, Rodape[playerid][0], 0);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][0], 0.000000, 2.535187);
    
PlayerTextDrawColor(playerid, Rodape[playerid][0], 0);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][0], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][0], 1);
    
PlayerTextDrawSetShadow(playerid, Rodape[playerid][0], 1);
    
PlayerTextDrawUseBox(playerid, Rodape[playerid][0], 1);
    
PlayerTextDrawBoxColor(playerid, Rodape[playerid][0], 170);
    
PlayerTextDrawTextSize(playerid, Rodape[playerid][0], -2.000000, 0.000000);
    
Rodape[playerid][1] = CreatePlayerTextDraw(playerid, 10.823518, 428.749969, "ID:");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][1], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][1], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][1], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][1], 0.449999, 1.600000);
    
PlayerTextDrawColor(playerid, Rodape[playerid][1], -16776961);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][1], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][1], 1);
    
Rodape[playerid][2] = CreatePlayerTextDraw(playerid, 127.529457, 428.166564, "R$:");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][2], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][2], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][2], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][2], 0.449999, 1.600000);
    
PlayerTextDrawColor(playerid, Rodape[playerid][2], 8388863);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][2], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][2], 1);
    
Rodape[playerid][3] = CreatePlayerTextDraw(playerid, 255.048370, 428.166595, "NICK:");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][3], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][3], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][3], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][3], 0.449999, 1.600000);
    
PlayerTextDrawColor(playerid, Rodape[playerid][3], -65281);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][3], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][3], 1);
    
Rodape[playerid][4] = CreatePlayerTextDraw(playerid, 406.824035, 428.166748, "LEVEL:");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][4], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][4], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][4], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][4], 0.449999, 1.600000);
    
PlayerTextDrawColor(playerid, Rodape[playerid][4], 65535);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][4], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][4], 1);
    
Rodape[playerid][5] = CreatePlayerTextDraw(playerid, 553.411193, 427.583251, "VIP:");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][5], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][5], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][5], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][5], 0.449999, 1.600000);
    
PlayerTextDrawColor(playerid, Rodape[playerid][5], -2147450625);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][5], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][5], 1);
    
Rodape[playerid][6] = CreatePlayerTextDraw(playerid, 503.058441, 394.917114, "www.brasilcidadevirtual.tk");
    
PlayerTextDrawBackgroundColor(playerid, Rodape[playerid][6], 51);
    
PlayerTextDrawAlignment(playerid, Rodape[playerid][6], 1);
    
PlayerTextDrawFont(playerid, Rodape[playerid][6], 1);
    
PlayerTextDrawLetterSize(playerid, Rodape[playerid][6], 0.264588, 1.535833);
    
PlayerTextDrawColor(playerid, Rodape[playerid][6], 16777215);
    
PlayerTextDrawSetOutline(playerid, Rodape[playerid][6], 0);
    
PlayerTextDrawSetProportional(playerid, Rodape[playerid][6], 1);
    return 
1;
}
public 
RodapeTD(playerid)
{
    if(
IsPlayerConnected(playerid))
    {
        new 
String[45];
        
PlayerTextDrawSetString(playerid, Rodape[playerid][0], "_");
        
PlayerTextDrawShow(playerid, Rodape[playerid][0]);
        
format(String, sizeof(String), "ID: ~w~%d", playerid);
        
PlayerTextDrawSetString(playerid, Rodape[playerid][1], String);
        
PlayerTextDrawShow(playerid, Rodape[playerid][1]);
        
format(String, sizeof(String), "R$: ~w~%d", GetPlayerGrana(playerid));
        
PlayerTextDrawSetString(playerid, Rodape[playerid][2], String);
        
PlayerTextDrawShow(playerid, Rodape[playerid][2]);
        
format(String, sizeof(String), "NICK: ~w~%s", PlayerName(playerid));
        
PlayerTextDrawSetString(playerid, Rodape[playerid][3], String);
        
PlayerTextDrawShow(playerid, Rodape[playerid][3]);
        
format(String, sizeof(String), "LEVEL: ~w~%d", dini_Int(file, "Level"));
        
PlayerTextDrawSetString(playerid, Rodape[playerid][4], String);
        
PlayerTextDrawShow(playerid, Rodape[playerid][4]);
        if(
IsPlayerVIP(playerid) == 1)
        {
            
format(String, sizeof(String), "VIP: ~w~Sim");
            
PlayerTextDrawSetString(playerid, Rodape[playerid][5], String);
            
PlayerTextDrawShow(playerid, Rodape[playerid][5]);
        }
        else
        {
            
format(String, sizeof(String), "VIP: ~w~Nao");
            
PlayerTextDrawSetString(playerid, Rodape[playerid][5], String);
            
PlayerTextDrawShow(playerid, Rodape[playerid][5]);
        }
        
        
PlayerTextDrawSetString(playerid, Rodape[playerid][6], "www.brasilcidadevirtual.tk");
        
PlayerTextDrawShow(playerid, Rodape[playerid][6]);
    }
    return 
1;
} 
Nгo testei se tiver erros vocк consegue arrumar, Й bem simples de fazer TD's

@CUIDADO

Suas strings contйm muitas cйlulas! Vocк nгo vai utilizar 500 cйlulas para pegar o level do player no mбximo: 35 б 45 caracteres
Reply


Messages In This Thread
TEXTDRAW BUGADO - by LeonardoMD - 10.09.2018, 22:44
Re: TEXTDRAW BUGADO - by Diggie - 10.09.2018, 22:49
Re: TEXTDRAW BUGADO - by LeonardoMD - 10.09.2018, 22:50
Re: TEXTDRAW BUGADO - by GuiKommander - 10.09.2018, 22:51
Re: TEXTDRAW BUGADO - by Diggie - 10.09.2018, 22:58
Re: TEXTDRAW BUGADO - by LeonardoMD - 10.09.2018, 23:01
Re: TEXTDRAW BUGADO - by GuiKommander - 10.09.2018, 23:10
Re: TEXTDRAW BUGADO - by LeonardoMD - 10.09.2018, 23:12
Re: TEXTDRAW BUGADO - by LeonardoMD - 10.09.2018, 23:23
Re: TEXTDRAW BUGADO - by GuiKommander - 10.09.2018, 23:34
Re: TEXTDRAW BUGADO - by Diggie - 10.09.2018, 23:39
Re: TEXTDRAW BUGADO - by LeonardoMD - 11.09.2018, 22:16
Re: TEXTDRAW BUGADO - by AutoMatic2 - 11.09.2018, 23:09
Re: TEXTDRAW BUGADO - by wearLy - 12.09.2018, 04:21
Re: TEXTDRAW BUGADO - by LeonardoMD - 12.09.2018, 22:44
Re: TEXTDRAW BUGADO - by ipsLuan - 12.09.2018, 22:57
Re: TEXTDRAW BUGADO - by LeonardoMD - 12.09.2018, 23:01
Re: TEXTDRAW BUGADO - by AutoMatic2 - 12.09.2018, 23:16
Re: TEXTDRAW BUGADO - by ipsLuan - 12.09.2018, 23:23
Re: TEXTDRAW BUGADO - by AutoMatic2 - 13.09.2018, 00:23
Re: TEXTDRAW BUGADO - by LeonardoMD - 14.09.2018, 21:51
Re: TEXTDRAW BUGADO - by LeonardoMD - 14.09.2018, 21:55

Forum Jump:


Users browsing this thread: 1 Guest(s)