private void OnEnable() { if (!HealthComp) { HealthComp = GetComponent <DHealth>(); } }
private void OnEnable() { if (!HealthComp) { HealthComp = GetComponent <DHealth>(); } if (HealthComp) { HealthComp.OnHealthChange.AddListener(HandleHealthChange); } if (!DestroyableComp) { DestroyableComp = GetComponent <ADestroyable>(); } }