Beispiel #1
0
        public virtual string GetYearTime()
        {
            if (Year == -1)
            {
                return("In a time before time, ");
            }

            string yearTime = "In " + Year + ", ";

            if (Seconds72 == -1)
            {
                return(yearTime);
            }

            int month = Seconds72 % 100800;

            if (month <= 33600)
            {
                yearTime += "early ";
            }
            else if (month <= 67200)
            {
                yearTime += "mid";
            }
            else if (month <= 100800)
            {
                yearTime += "late ";
            }

            int season = Seconds72 % 403200;

            if (season < 100800)
            {
                yearTime += "spring, ";
            }
            else if (season < 201600)
            {
                yearTime += "summer, ";
            }
            else if (season < 302400)
            {
                yearTime += "autumn, ";
            }
            else if (season < 403200)
            {
                yearTime += "winter, ";
            }

            return(yearTime + " (" + Formatting.AddOrdinal(Day) + " of " + MonthName + ") ");
        }