public EquipedWeapon Equip(Transform carrier, Transform rightHand, Transform leftHand, Animator animator) { AnimationHandler.OverrideAnimations(animator, animationClip, "Attack"); EquipedWeapon spawnedWeapon = Spawn(carrier, SelectTransform(rightHand, leftHand)); return(spawnedWeapon); }
private void Start() { for (int i = 0; i < startAbilities.Count; i++) { if (startAbilities[i] == null) { continue; } AnimationHandler.OverrideAnimations(animator, startAbilities[i].animationClip, "Cast" + (i + 1)); } }
public void SetNewAbility(AbilityGem gem, AbilityCooldownDisplay slot) { if (gem == null) { slot.SetAbility(null); return; } Ability abilityInstance = InstanciateAbility(gem.ability); slot.SetAbility(abilityInstance); abilityInstance.baseEffectValue = gem.baseEffectValue; abilityInstance.range = gem.ability.range; if (animator == null) { animator = GetComponentInChildren <Animator>(); } AnimationHandler.OverrideAnimations(animator, gem.ability.animationClip, "Cast" + slot.index); }
private void Start() { AnimationHandler.OverrideAnimations(GetComponent <Animator>(), ability.animationClip, "Attack"); }