Exemplo n.º 1
0
 void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     nPC.agent.isStopped = true;
     nPC.animator.SetBool("Walk", false);
     nPC.animator.SetTrigger("Meow");
     InvokeRepeating("UpdatePlayerPosition", 0, 1f);
 }
Exemplo n.º 2
0
 private void OnEnable()
 {
     nPC                 = GetComponent <AllNPC>();
     napTime             = nPC.napTime;
     nPC.agent.isStopped = true;
     wakingUp            = false;
     nPC.animator.SetTrigger("Tired");
 }
Exemplo n.º 3
0
 private void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     // Disabling auto-braking allows for continuous movement
     // between points (ie, the agent doesn't slow down as it
     // approaches a destination point).
     Invoke("GetMoving", 0.01f);
 }
Exemplo n.º 4
0
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     Invoke("Eat", 0.01f);
 }
Exemplo n.º 5
0
 private void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
 }
 public void OnEnable()
 {
     nPC             = GetComponent <AllNPC>();
     nPC.agent.speed = 2;
 }
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     Invoke("GetMoving", .1f);
 }
Exemplo n.º 8
0
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     //nPC.agent.speed = 5f;
     InvokeRepeating("UpdateFoodPosition", 0, .5f);
 }
Exemplo n.º 9
0
 void Start()
 {
     nPC = GetComponent <AllNPC>();
 }