コード例 #1
0
        private static string getSpecialOrderDetails(SpecialOrder order)
        {
            int    daysLeft             = order.GetDaysLeft();
            string description          = order.GetDescription();
            string objectiveDescription = "";
            string name        = order.GetName();
            int    moneyReward = order.GetMoneyReward();

            // Get each objectives
            for (int i = 0; i < order.GetObjectiveDescriptions().Count; i++)
            {
                objectiveDescription += order.GetObjectiveDescriptions()[i] + ", \n";
            }

            string toReturn = $"{name}\n\tDescription:{description}\n\tObjectives: {objectiveDescription}";

            if (order.IsTimedQuest())
            {
                toReturn = $"{toReturn}\n\tTime: {daysLeft} days";
            }

            if (order.HasMoneyReward())
            {
                toReturn = $"{toReturn}\n\tReward: {moneyReward}g";
            }

            return(toReturn);
        }