03.12.2010, 09:32
I'm not sure is this posted before, but it's a useful one. Convert integer value from 1 to 12 to a month
Written by me of course
Written by me of course
pawn Код:
stock NumberToMonth(number)
{
new month[24];
if (number < 1 || number > 12) month = "INVALID_MONTH";
if (number == 1) month = "January";
if (number == 2) month = "February";
if (number == 3) month = "March";
if (number == 4) month = "April";
if (number == 5) month = "May";
if (number == 6) month = "June";
if (number == 7) month = "July";
if (number == 8) month = "August";
if (number == 9) month = "September";
if (number == 10) month = "October";
if (number == 11) month = "November";
if (number == 12) month = "December";
return month;
}