protected virtual void Cmd_UpdateSkill(int skill_hash) { // validate can hit // return casting percent // make enemy health lower by skill power string result = "success"; if (currentTarget) { PlayerControllerComponent pc = currentTarget.GetComponent <PlayerControllerComponent>(); SkillTemplate skill = characterClass.skillsList.Find(item => item.hash == skill_hash); if (skill) { pc.takeDamage(skill.baseImpact); } else { result = "Could not find skill"; } } RpcCorrectClientSkillHit(result); }