Exemplo n.º 1
0
        public string GetAttributeNote(AttributeCode attribute)
        {
            int baseValue = 0, raceValue = 0, improvementsValue = 0;

            if (BaseAttributes.ContainsKey(attribute))
            {
                baseValue = BaseAttributes[attribute];
            }
            else if (DerivedAttributes.ContainsKey(attribute))
            {
                baseValue = DerivedAttributes[attribute];
            }
            else
            {
                throw new ArgumentOutOfRangeException("Tried to get nonexistent attribute.");
            }

            raceValue = Race.GetAttribute(attribute, Female && ApplyGender);

            return("Rasa(" + raceValue + ") + Úrovně(" + baseValue + ") + Ostatní(" + improvementsValue + ")");
        }
Exemplo n.º 2
0
        public int GetAttribute(AttributeCode attribute)
        {
            int baseValue = 0, raceValue, improvementsValue = 0;

            if (BaseAttributes.ContainsKey(attribute))
            {
                baseValue = BaseAttributes[attribute];
            }
            else if (DerivedAttributes.ContainsKey(attribute))
            {
                baseValue = DerivedAttributes[attribute];
            }
            else
            {
                throw new ArgumentOutOfRangeException("Tried to get nonexistent attribute.");
            }

            raceValue = Race.GetAttribute(attribute, Female && ApplyGender);

            return(baseValue + raceValue + improvementsValue);
        }