Pedro Gomes b29b17ebfd New systems & spells
- Fixed issue on projectile hit events that triggered multiple times.
- Implemented % costs for health and mana
- Updated key binding UI slots to show health costs if present
- New Necromancer projectile AoEOverTime ability: Bonestorm.
- New Vamp/Cultist/Satanist summon ability: Bloody Shadow.
2024-12-29 18:39:40 +00:00

32 lines
909 B
C#

using Kryz.CharacterStats;
using Kryz.CharacterStats.Examples;
using Photon.Pun;
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;
//character.MaxHealth.RemoveAllModifiersFromSource(GameConstants.ObjectSources.LevelSource);
//
//character.MaxHealth.AddModifier(new StatModifier(baseMaxValue * currentLevel * GameConstants.CharacterStatsBalancing.BaseMaxHealthGrowthPerLevel, StatModType.Flat, GameConstants.ObjectSources.LevelSource));
maxValue = character.MaxHealth.Value;
CalculateRegenValueBasedOnStat();
onMaxHealthChanged.Invoke(maxValue);
}
}