コード例 #1
0
 void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     nPC.agent.isStopped = true;
     nPC.animator.SetBool("Walk", false);
     nPC.animator.SetTrigger("Meow");
     InvokeRepeating("UpdatePlayerPosition", 0, 1f);
 }
コード例 #2
0
 private void OnEnable()
 {
     nPC                 = GetComponent <AllNPC>();
     napTime             = nPC.napTime;
     nPC.agent.isStopped = true;
     wakingUp            = false;
     nPC.animator.SetTrigger("Tired");
 }
コード例 #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);
 }
コード例 #4
0
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     Invoke("Eat", 0.01f);
 }
コード例 #5
0
 private void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
 }
コード例 #6
0
 public void OnEnable()
 {
     nPC             = GetComponent <AllNPC>();
     nPC.agent.speed = 2;
 }
コード例 #7
0
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     Invoke("GetMoving", .1f);
 }
コード例 #8
0
 public void OnEnable()
 {
     nPC = GetComponent <AllNPC>();
     //nPC.agent.speed = 5f;
     InvokeRepeating("UpdateFoodPosition", 0, .5f);
 }
コード例 #9
0
 void Start()
 {
     nPC = GetComponent <AllNPC>();
 }