Jump to content
  • 0

Problema ceas


gabyskm96

Question

Salut am si eu un ceas(mie imi place) care indica si ziua dar nush cum sa le trec corect la mine uneori numai luni sta..sau nu indica ziua corect [pawn]}

public settime(){

new hour,minute,second;

new string[256];

gettime(hour,minute,second);

if (minute <= 9){format(string,25,"%d:0%d",hour,minute);}

else {format(string,25,"%d:%d",hour,minute);}

TextDrawSetString(Ora,string);

//

if (minute <= 9){format(string,25,":%d",second);}

else {format(string,25,":%d",second);}

TextDrawSetString(Secunde,string);

//

SetWorldTime(hour);

new day, month, year;

new weekday;

getdate(day, month, year);

weekday = GetWeekdayNum(day, month, year);

if(weekday == 1){TextDrawSetString(Zile,"Luni");}

if(weekday == 2){TextDrawSetString(Zile,"Marti");}

if(weekday == 3){TextDrawSetString(Zile,"Miercuri");}

if(weekday == 4){TextDrawSetString(Zile,"Joi");}

if(weekday == 5){TextDrawSetString(Zile,"Vineri");}

if(weekday == 6){TextDrawSetString(Zile,"Sambata");}

if(weekday == 7){TextDrawSetString(Zile,"Duminica");}

return 1;

}[/pawn] Asta este ceasul gaby.jpg  Daca va mai trebuie ceva imi spuneti

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.