[AJUDA]TextDraw
#8

Pelo que vi vocк quer fazer um text draw para horas entгo vamos lб:
pawn Код:
// Topo do Gamemode
new Text: TextHoras[MAX_PLAYERS];
formard AtualizarHora();
//Ongamemodeinit
SetTimer("AtualizarHora", 60000, true);
for(new i; i < GetMaxPlayers(); i ++)
{
TextHoras[i] = TextDrawCreate(548.000000,23.000000," ");
TextDrawAlignment(TextHoras[i],0);
TextDrawBackgroundColor(TextHoras[i],0xFFFFFFff);
TextDrawFont(TextHoras[i],3);
TextDrawLetterSize(TextHoras[i],0.599999,1.700000);
TextDrawColor(TextHoras[i],0x000000ff);
TextDrawSetOutline(TextHoras[i],1);
TextDrawSetProportional(TextHoras[i],1);
TextDrawSetShadow(TextHoras[i],1);
}
//no inicio de onplayerspawn
TextDrawShowForPlayer(playerid, TextHoras[playerid]);
//No inicio de onplayerdeath
TextDrawHidePlayer(playerid, TextHoras[playerid]);
//No fim do seu gamemode
public AtualizarHora()
{
new string[256];
new horas, minutos;
gettime(horas, minutos);
format(string,50,"%02d:%02d",horas, minutos);
TextDrawSetString(TextHoras[i],string);
return 1;
}
Caso tenha erros ou nгo funcione poste aki, abraзos.
Reply


Messages In This Thread
[AJUDA]TextDraw - by egonzks - 15.12.2010, 10:14
Re: [AJUDA]TextDraw - by [Ips]Guh - 15.12.2010, 10:34
Re: [AJUDA]TextDraw - by [Banido]HigorOliver - 15.12.2010, 10:35
Re: [AJUDA]TextDraw - by egonzks - 15.12.2010, 10:47
Re: [AJUDA]TextDraw - by mafelis - 15.12.2010, 11:09
Re: [AJUDA]TextDraw - by egonzks - 15.12.2010, 11:38
Re: [AJUDA]TextDraw - by mafelis - 15.12.2010, 12:39
Re: [AJUDA]TextDraw - by NathanLive - 15.12.2010, 12:50
Re: [AJUDA]TextDraw - by egonzks - 16.12.2010, 11:34
Re: [AJUDA]TextDraw - by rjjj - 16.12.2010, 11:44

Forum Jump:


Users browsing this thread: 3 Guest(s)