public void LevelUpV2(IRandom random, EnhancementCostSheetV2.Row row, bool isGreatSuccess) { level++; var rand = isGreatSuccess ? row.BaseStatGrowthMax :random.Next(row.BaseStatGrowthMin, row.BaseStatGrowthMax + 1); var ratio = rand.NormalizeFromTenThousandths(); var baseStat = StatsMap.GetStat(UniqueStatType, true) * ratio; if (baseStat > 0) { baseStat = Math.Max(1.0m, baseStat); } StatsMap.AddStatValue(UniqueStatType, baseStat); if (GetOptionCount() > 0) { UpdateOptionsV2(random, row, isGreatSuccess); } }
public decimal GetIncrementAmountOfEnhancement() { return(Math.Max(1.0m, StatsMap.GetStat(UniqueStatType, true) * 0.1m)); }