public void Setup(CharacterDefinition definition) { #if UNITY_EDITOR if (characterUI == null) { characterUI = GetComponent <CombatCharacterUI>(); } #endif this.definition = definition; this.currentHealth = definition == null? 0 : definition.Health; characterUI.OnDefinitionChange(definition); }
private void Start() { characterUI = GetComponent <CombatCharacterUI>(); }
protected override void Start() { base.Start(); characterUI = slot.GetComponent <CombatCharacterUI>(); }