using Kryz.CharacterStats.Examples; using System.Collections; using System.Collections.Generic; using UnityEngine; public class PlayerHealth : Health { int currentLevel; protected override void Awake() { base.Awake(); } public override void CalculateMaxValueBasedOnStat() { currentLevel = ((PlayerCharacterStats)character).level.currentLevel - 1; maxValue = (baseMaxValue + (baseMaxValue * currentLevel * GameConstants.CharacterStatsBalancing.BaseMaxHealthGrowthPerLevel)) + character.Vitality.Value * GameConstants.CharacterStatsBalancing.VitalityToHealthRate; CalculateRegenValueBasedOnStat(); onMaxHealthChanged.Invoke(maxValue); } }