示例#1
0
 private void OnCollisionEnter(Collision collision)
 {
     if (collision.gameObject.CompareTag("Throwable") && dsg.getCollectedStarts() == dsg.getNbStarsInGame())
     {
         collision.gameObject.GetComponent <Rigidbody>().velocity = Vector3.zero;
         SteamVR_LoadLevel.Begin(sceneLoading);
     }
 }
示例#2
0
 private void OnCollisionEnter(Collision collision)
 {
     if (collision.gameObject.CompareTag("Throwable") && dsg.getCollectedStarts() == dsg.getNbStarsInGame())
     {
         collision.gameObject.GetComponent <Rigidbody>().velocity   = Vector3.zero;
         canvas.transform.GetChild(0).GetComponent <Image>().sprite = victorySprite;
         canvas.SetActive(true);
     }
 }