Пример #1
0
    // Use this for initialization
    void Start()
    {
        triggersFinished = new bool[NUM_TRIGGERS];
        for (int i = 0; i < NUM_TRIGGERS; i++)
        {
            triggersFinished[i] = false;
        }

        rotationScript     = rotationGizmo.GetComponent <RotationGizmo>();
        fuseEvent          = eventSystem.GetComponent <FuseEvent>();
        selectPart         = eventSystem.GetComponent <SelectPart>();
        partButtonClicked  = false;
        conversationSystem = GameObject.Find("ConversationSystem");
        done = false;

        //disable part buttons so player can't use them while Dresha talks
        foreach (Button b in partButtons)
        {
            b.interactable = false;
        }
        //disable clicking on black regions while Dresha talks
        //could throw error if any of the objects in attachments do not have a MeshCollider or BoxCollider
        foreach (GameObject a in attachments)
        {
            BoxCollider bcollide = a.GetComponent <BoxCollider>();
            if (bcollide == null)
            {
                a.GetComponent <MeshCollider>().enabled = false;
            }
            else
            {
                bcollide.enabled = false;
            }
        }
        SimpleData.WriteStringToFile("LeapData.txt", "***This is another try at " + DateTime.Now.ToString() + ".");
        LeapStatic.resetConstructionObject("tutorial1");
    }
 // Use this for initialization
 void Start()
 {
     LeapStatic.resetConstructionObject("construction");
 }