public void TakeDamage(HPUnit damage) { if (invincibleTimer.Active) { return; } playerHealth.health.TakeDamage(damage); damageText.Value = damage; polarStar.DamageExperience(damage * 2); kinematicsY.velocity = Math.Min(kinematicsY.velocity, -ShortJumpSpeed); invincibleTimer.Reset(); }