void Awake() { rpgCharacterController = GetComponent <RPGCharacterControllerFREE>(); //Find the Animator component. animator = GetComponentInChildren <Animator>(); StartCoroutine(_HideAllWeapons(false, false)); }
public void Die() { rpgCharacterController = gameObject.GetComponent <RPGCharacterAnims.RPGCharacterControllerFREE>(); animator = gameObject.GetComponent <Animator>(); gameObject.GetComponent <RPGCharacterAnims.RPGCharacterInputControllerFREE>().enabled = false; rpgCharacterController.movementAnimationSpeed = 0f; animator.SetTrigger("Death1Trigger"); }
void Awake() { superCharacterController = GetComponent <SuperCharacterController>(); rpgCharacterController = GetComponent <RPGCharacterControllerFREE>(); rpgCharacterInputController = GetComponent <RPGCharacterInputController>(); navMeshAgent = GetComponent <UnityEngine.AI.NavMeshAgent>(); animator = GetComponentInChildren <Animator>(); rb = GetComponent <Rigidbody>(); if (rb != null) { //Set restraints on startup if using Rigidbody. rb.constraints = RigidbodyConstraints.FreezeRotationX | RigidbodyConstraints.FreezeRotationZ; } //Set currentState to idle on startup. currentState = RPGCharacterState.Idle; rpgCharacterState = RPGCharacterState.Idle; }
void Awake() { rpgCharacterController = GetComponent <RPGCharacterControllerFREE>(); rpgCharacterMovementController = GetComponent <RPGCharacterMovementControllerFREE>(); }
// Start is called before the first frame update void Start() { InvokeRepeating("Attack", 1f, 2.5f); rpgCharacterController = GetComponent <RPGCharacterControllerFREE>(); }
// Start is called before the first frame update void Start() { InvokeRepeating("Attack", 1f, Random.Range(0.25f, 5f)); rpgCharacterController = GetComponent <RPGCharacterControllerFREE>(); rpgCharacterMovementController = GetComponent <RPGCharacterMovementControllerFREE>(); }
void Awake() { rpgCharacterController = player.GetComponent <RPGCharacterAnims.RPGCharacterControllerFREE>(); playerManager = GameObject.Find("GameManager").GetComponent <PlayerManager>(); myStats = player.GetComponent <CharacterStats>(); }
void Start() { rpgCharacterController = player.GetComponent <RPGCharacterAnims.RPGCharacterControllerFREE>(); }