Пример #1
0
 //Load all scripts that will be controlled by scene flow controller
 void GetScripts()
 {
     audioCS        = GameObject.FindGameObjectWithTag("AudioController").GetComponent <AudioControlScript>();
     dialogueScript = dialogueUI.GetComponent <DialogueHandler>();
     mapScript      = GameObject.FindGameObjectWithTag("GameController").GetComponent <OverworldMapControl>();
     camScript      = GameObject.FindGameObjectWithTag("MainCamera").GetComponent <MapCameraController>();
 }
Пример #2
0
 // Start is called before the first frame update
 void Start()
 {
     //get reference to audio
     m_audio = GameObject.FindGameObjectWithTag("Audio").GetComponent <AudioControlScript>();
     //get reference to Canvas controller
     m_canvas = GameObject.FindGameObjectWithTag("Canvas").GetComponent <CanvasController>();
 }
Пример #3
0
 void Awake()
 {
     sceneFC     = GameObject.FindGameObjectWithTag("GameController").GetComponent <SceneFlowController>();
     audioCS     = GameObject.FindGameObjectWithTag("AudioController").GetComponent <AudioControlScript>();
     lDefaultPos = lPortPos = leftPortrait.rectTransform.anchoredPosition;
     rDefaultPos = rPortPos = rightPortrait.rectTransform.anchoredPosition;
     ConstructDicts();
     Reset();
 }
Пример #4
0
    bool m_isPlayerKilled = false;            //flag

    private void Start()
    {
        m_audioSource = GetComponent <AudioSource>();
        //play sound with slight delay
        Invoke("PlaySound", 0.25f);
        m_audioScript = GameObject.FindGameObjectWithTag("Audio").GetComponent <AudioControlScript>();

        //get particles
        m_ps = GetComponentsInChildren <ParticleSystem>();
    }
Пример #5
0
 private void Start()
 {
     m_audio = GameObject.FindGameObjectWithTag("Audio").GetComponent <AudioControlScript>();
 }