コード例 #1
0
 void GetReferences()
 {
     m_scientistWinScript = scientist.GetComponent <ScientistWin>();
     m_safeAS             = safe.GetComponent <AudioSource>();
     m_freezeControls     = gameController.GetComponent <FreezeControls>();
     m_hackingDocuments   = ai.GetComponent <HackingDocuments>();
     m_safeAnim           = safe.GetComponent <Animator>();
 }
コード例 #2
0
 void Start()
 {
     m_audioSource = gameObject.GetComponent <AudioSource>();
     Invoke("GetPassword", 1f);
     m_percentageSearched = 0f;
     m_percentageImage    = cabinetCanvas.GetComponentInChildren <Image>();
     m_passwordText       = cabinetCanvas.GetComponentInChildren <Text>();
     m_freezePlayerScript = gameController.GetComponent <FreezeControls>();
 }
コード例 #3
0
 // Use this for initialization
 void Start()
 {
     m_audioSource           = gameObject.GetComponent <AudioSource>();
     m_downloadingTime       = downloadingTime;
     m_sequenceTime          = m_downloadingTime;
     m_starsignTime          = m_downloadingTime;
     m_receivePasswordScript = gameObject.GetComponent <ReceivePasswords>();
     m_gameController        = GameObject.FindGameObjectWithTag("GameController");
     m_freezeControlScript   = m_gameController.GetComponent <FreezeControls>();
     m_lengthNumber          = m_letters.Length;
     Invoke("RecievePassword", 1f);
 }
コード例 #4
0
    void Start()
    {
        m_audioSource            = gameObject.GetComponent <AudioSource>();
        m_camera                 = gameObject.GetComponentInChildren <Camera>();
        m_gameController         = GameObject.FindGameObjectWithTag("GameController");
        m_ai                     = GameObject.FindGameObjectWithTag("AI");
        m_cameraControllerScript = m_ai.GetComponent <CameraController>();
        m_freezeControlScript    = m_gameController.GetComponent <FreezeControls>();
        m_cameraTime             = m_shutOutTime;

        //gameObject.SetActive(false);
    }
コード例 #5
0
ファイル: Safe.cs プロジェクト: philipnewsham/ArtificialTrust
    // Use this for initialization
    void Start()
    {
        m_safeLockScript = GetComponent <SafeLocks>();
        m_firstPersonControllerScript = scientist.GetComponent <FirstPersonController>();
        m_freezeControls        = gameController.GetComponent <FreezeControls>();
        m_agentWinScript        = scientist.GetComponent <AgentWin>();
        m_hackingDocumentScript = ai.GetComponent <HackingDocuments>();
        m_receivePasswordScript = gameObject.GetComponent <ReceivePasswords>();

        m_countingDown = m_lockedOutTime;

        Invoke("GetPassword", 1f);
        starSignImage.sprite = starSigns[m_currentStarSignNo];
        RandomiseButtonOrder();
        m_correctStarSign = Random.Range(0, 12);

        //print("correct star sign is: " + m_correctStarSign);
        CheckLocks();
    }
コード例 #6
0
    void Start()
    {
        //print("Start");
        m_scientistWinScript = scientist.GetComponent <ScientistWin>();
        m_safeAS             = safe.GetComponent <AudioSource>();
        m_freezeControls     = gameController.GetComponent <FreezeControls>();
        m_hackingDocuments   = ai.GetComponent <HackingDocuments>();
        m_safeAnim           = safe.GetComponent <Animator>();
        UpdatePanels();
        m_lockedOutTime      = lockedOutTime;
        m_countingDown       = m_lockedOutTime;
        locksText.text       = string.Format("({0}/3) Locks Unlocked", m_locksUnlocked);
        m_correctStarSign    = Random.Range(0, 12);
        starsignImage.sprite = starsigns[m_currentStarsign];
        string starsignMessage = string.Format("////CONFIDENTIAL////\n---For Authorised Personnel Only---\nThe star sign that unlocks the safe is {0}", starsignNames[m_correctStarSign]);

        documentButtons[0].GetComponent <DocumentButton>().documentText = string.Format("The star sign that unlocks the safe is {0}", starsignNames[m_correctStarSign]);
        scientistComputerScript.ReceiveStarsign(starsignMessage);

        m_hackingDocuments.RecieveDocumentMessages(starsignMessage, 4);
        safeCanvas.SetActive(false);
    }
コード例 #7
0
 void Start()
 {
     m_gameController      = GameObject.FindGameObjectWithTag("GameController");
     m_freezeControlScript = m_gameController.GetComponent <FreezeControls>();
     m_audioSource         = gameObject.GetComponent <AudioSource>();
 }