[Ajuda] Como consertar relogio !?
#3

Quote:

#include <a_samp>

new Text:Relogio;
new Textata;


public OnGameModeInit()
{
print("-----------------------------");
print("Sistema de Relogio Carregado");
print("Desenvolvido por: Kanuy");
print("-----------------------------");

SetTimer("Hora", 1000, true);


Relogio = TextDrawCreate(470.000000,4.000000,"");
Data = TextDrawCreate(550.000000,23.000000,"");
TextDrawAlignment(Relogio,0);
TextDrawAlignment(Data,0);
TextDrawBackgroundColor(Relogio,0x000000AA);
TextDrawBackgroundColor(Data,0x000000AA);
TextDrawFont(Relogio,3);
TextDrawLetterSize(Relogio,0.500000,2.000000);
TextDrawFont(Data,3);
TextDrawLetterSize(Data,0.399999,2.000000);
TextDrawColor(Relogio,0xffffffff);
TextDrawColor(Data,0xffffffff);
TextDrawSetProportional(Relogio,1);
TextDrawSetProportional(Data,1);
TextDrawSetShadow(Relogio,1);
TextDrawSetShadow(Data,1);
TextDrawSetOutline(Relogio,1);
TextDrawSetOutline(Data,1);
TextDrawShowForAll(Relogio);
TextDrawShowForAll(Data);
return 1;
}


public OnPlayerSpawn(playerid)
{
TogglePlayerControllable(playerid, true);
TextDrawHideForAll(Relogio);
TextDrawShowForPlayer(playerid, Relogio);
TextDrawHideForAll(Data);
TextDrawShowForPlayer(playerid, Data);
return 1;
}


forward Hora();public Hora()
{
static _ist[20], d, m, a; getdate(a, m, d);
format(_ist, sizeof _ist, " %i/%02d/2014", d, m);
TextDrawSetString(Relogio, _ist);

gettime(a, m, d);
format(_ist, sizeof _ist, "%02d:%02d:%02d",a,m,d);
TextDrawSetString(Data, _ist);

TextDrawShowForAll(Data);
TextDrawShowForAll(Relogio);
}

ta ai
Reply


Messages In This Thread
Como consertar relogio !? - by ces123 - 27.07.2014, 15:58
Re: Como consertar relogio !? - by ViniBorn - 27.07.2014, 16:04
Re: Como consertar relogio !? - by ces123 - 27.07.2014, 16:06
Re: Como consertar relogio !? - by Petrick™ - 27.07.2014, 16:14
Re: Como consertar relogio !? - by ces123 - 27.07.2014, 16:17
Re: Como consertar relogio !? - by rebelox - 27.07.2014, 16:26
Re: Como consertar relogio !? - by ces123 - 27.07.2014, 17:36
Re: Como consertar relogio !? - by pivetesgames - 27.07.2014, 17:40

Forum Jump:


Users browsing this thread: 2 Guest(s)