コード例 #1
0
 public BattlePokemon(
     string name,
     string?nickname,
     int level,
     IPermanentStat health,
     IPermanentStat attack,
     IPermanentStat defense,
     IPermanentStat special,
     IPermanentStat speed,
     IBattleStat accuracy,
     IBattleStat evasion,
     decimal weight,
     decimal height,
     IReadOnlyIndexedSet <IType> types,
     IReadOnlyIndexedSet <IMove> moves,
     ITier tier)
 {
     Name     = name;
     Nickname = nickname;
     Level    = level;
     Health   = health;
     Attack   = attack;
     Defense  = defense;
     Special  = special;
     Speed    = speed;
     Accuracy = accuracy;
     Evasion  = evasion;
     Weight   = weight;
     Height   = height;
     Types    = types;
     Moves    = moves;
     Tier     = tier;
 }
コード例 #2
0
        public int CalculateHp(IPermanentStat stat)
        {
            var baseValue = stat.BaseValue;
            var iv        = stat.IndividualValue;
            var ev        = stat.EffortValue;
            var level     = stat.Level;

            return(CalculateHp(baseValue, iv, ev, level));
        }