/// <summary> /// Initialize the collider layers after the UltimateCharacterLocomotion has been initialized. /// </summary> private void Start() { if (!string.IsNullOrEmpty(m_DamagedEffectName)) { m_DamagedEffect = m_CharacterLocomotion.GetEffect(Shared.Utility.TypeUtility.GetType(m_DamagedEffectName), m_DamagedEffectIndex); } }
/// <summary> /// Initialize the collider layers after the UltimateCharacterLocomotion has been initialized. /// </summary> protected override void Start() { base.Start(); if (!string.IsNullOrEmpty(m_DamagedEffectName)) { m_DamagedEffect = m_CharacterLocomotion.GetEffect(Shared.Utility.TypeUtility.GetType(m_DamagedEffectName), m_DamagedEffectIndex); } }
/// <summary> /// Retrieves the specified effect. /// </summary> public override void OnStart() { var target = GetDefaultGameObject(m_TargetGameObject.Value); if (target != m_PrevTarget) { m_CharacterLocomotion = target.GetCachedComponent <UltimateCharacterLocomotion>(); m_Effect = m_CharacterLocomotion.GetEffect(TaskUtility.GetTypeWithinAssembly(m_EffectType.Value)); m_PrevTarget = target; } }
/// <summary> /// Awake is called after all of the actions have been initialized. /// </summary> public override void Awake() { base.Awake(); if (!string.IsNullOrEmpty(m_EffectName)) { m_Effect = m_CharacterLocomotion.GetEffect(Shared.Utility.TypeUtility.GetType(m_EffectName), m_EffectIndex); } if (m_Effect == null) { Debug.LogError($"Error: Unable to find effect {m_EffectName}."); } }
/// <summary> /// Initialize the collider layers after the UltimateCharacterLocomotion has been initialized. /// </summary> private void Start() { m_ColliderGameObjects = new GameObject[m_CharacterLocomotion.ColliderCount]; for (int i = 0; i < m_ColliderGameObjects.Length; ++i) { m_ColliderGameObjects[i] = m_CharacterLocomotion.Colliders[i].gameObject; } m_ColliderLayers = new int[m_CharacterLocomotion.ColliderCount]; if (!string.IsNullOrEmpty(m_DamagedEffectName)) { m_DamagedEffect = m_CharacterLocomotion.GetEffect(UnityEngineUtility.GetType(m_DamagedEffectName), m_DamagedEffectIndex); } }