Example #1
0
        public int Get(AttributeComponentType type)
        {
            int val = 0;

            switch (type)
            {
            case AttributeComponentType.Current:
                val = current;
                break;

            case AttributeComponentType.Start:
                val = start;
                break;

            case AttributeComponentType.Minimum:
                val = minimum;
                break;

            case AttributeComponentType.Maximum:
                val = maximum;
                break;

            case AttributeComponentType.Modifier:
                val = modifier;
                break;

            case AttributeComponentType.Spent:
                val = spent;
                break;

            case AttributeComponentType.Exp_Cost:
                val = expCost;
                break;

            default:
                break;
            }

            return(val);
        }
Example #2
0
        public void Modify(AttributeComponentType type, int value)
        {
            switch (type)
            {
            case AttributeComponentType.Current:
                current += value;
                break;

            case AttributeComponentType.Start:
                start += value;
                break;

            case AttributeComponentType.Minimum:
                minimum += value;
                break;

            case AttributeComponentType.Maximum:
                maximum += value;
                break;

            case AttributeComponentType.Modifier:
                modifier += value;
                break;

            case AttributeComponentType.Spent:
                spent += value;
                break;

            case AttributeComponentType.Exp_Cost:
                expCost += value;
                break;

            default:
                break;
            }

            Check();
        }
Example #3
0
 public int GetAttributeValue(AttributeListType listType, AttributeComponentType type, int attribute)
 {
     return(lists[(int)listType].Attributes[attribute].Get(type));
 }