Esempio n. 1
0
    void Start()
    {
        // Retrieve the scripts from the paintings
        painting_scripts = new PaintingColliderDetector[paintings.Length];

        for (int i = 0; i < paintings.Length; i++)
        {
            painting_scripts[i] = paintings[i].GetComponent <PaintingColliderDetector>();
        }

        // Disable the exit door collider
        if (exitDoor != null)
        {
            doorTeletransporterScript = exitDoor.GetComponent <DoorTeletransporter>();
            if (doorTeletransporterScript != null)
            {
                doorTeletransporterScript.Disable();
            }
        }

        if (dialogManagerHolder != null)
        {
            dialogManagerScript = dialogManagerHolder.GetComponent <DialogManager>();
        }
    }
Esempio n. 2
0
 private void Start()
 {
     if (exitDoor != null)
     {
         doorTeletransporterScript = exitDoor.GetComponent <DoorTeletransporter>();
         if (doorTeletransporterScript != null)
         {
             doorTeletransporterScript.Disable();
         }
         else
         {
             Debug.Log("Door Teletransporter Script cannot be found on object");
         }
     }
 }
Esempio n. 3
0
    void Awake()
    {
        if (dialogManagerHolder)
        {
            dialogManagerScript = dialogManagerHolder.GetComponent <DialogManager>();
        }

        if (ExitDoor != null)
        {
            doorTeletransporterScript = ExitDoor.GetComponent <DoorTeletransporter>();
            if (doorTeletransporterScript != null)
            {
                doorTeletransporterScript.Disable();
            }
        }

        MAX_PAINTINGS            = paintingCheckers.Length;
        currentFinishedPaintings = 0;
    }
Esempio n. 4
0
    private void Awake()
    {
        if (Door != null)
        {
            doorTeletransporterScript = Door.GetComponent <DoorTeletransporter>();
            if (doorTeletransporterScript != null)
            {
                doorTeletransporterScript.Disable();
            }
            else
            {
                Debug.Log("Door Teletransporter Script cannot be found on object");
            }
        }

        if (DialogManagerHolder)
        {
            dialogManagerScript = DialogManagerHolder.GetComponent <DialogManager>();
        }

        win = false;
    }
Esempio n. 5
0
    private void Start()
    {
        if (dialogManagerHolder != null)
        {
            dialogManagerScript = dialogManagerHolder.GetComponent <DialogManager>();
        }

        if (exitDoor != null)
        {
            doorTeletransporterScript = exitDoor.GetComponent <DoorTeletransporter>();
            if (doorTeletransporterScript != null)
            {
                doorTeletransporterScript.Disable();
            }
        }

        foreach (VRTK_SnapDropZone sdz in snapDropZones)
        {
            sdz.ObjectSnappedToDropZone     += OnTrashSnapped;
            sdz.ObjectUnsnappedFromDropZone += OnTrashUnsnapped;
        }
    }
Esempio n. 6
0
 internal void OnFruitUnsnapped(object sender, SnapDropZoneEventArgs e)
 {
     doorTeletransporterScript.Disable();
 }