Exemple #1
0
        public Form1()
        {
            // Register the event with event handler
            delSpeak = Speak;

            InitializeComponent();
        }
Exemple #2
0
    // Update is called once per frame

    void Start()
    {
        soundManager = GameObject.FindWithTag("MusicManager");
        makeSound    = soundManager.GetComponent <MakeSound> ();
        audioSource  = GetComponent <AudioSource> ();

        sounds = new AudioClip[makeSound.audioclips.Length];
        for (int a = 0; a < makeSound.audioclips.Length; a++)
        {
            sounds [a] = makeSound.audioclips [a];
        }


        GameObject birdGenObj = GameObject.FindWithTag("BirdGenerator");

        birdGenerator     = birdGenObj.GetComponent <BirdGenerator> ();
        birdKeys          = birdGenerator.birdKeys;
        allowedToPlay     = true;
        happyParticles    = transform.Find("BirdHappyParticles").GetComponent <ParticleSystem> ();
        confusedParticles = transform.Find("BirdConfusedParticles").GetComponent <ParticleSystem> ();
        playingParticles  = transform.Find("BirdPlayingParticles").GetComponent <ParticleSystem> ();
        birdRenderer      = transform.Find("pCube8").GetComponent <Renderer> ();

        callUI = GameObject.FindWithTag("MainCamera").GetComponent <Call_UI> ();


        playingParticles.startColor  = particleColor;
        confusedParticles.startColor = particleColor;

        birdRenderer.material = birdMaterial;
        confusedParticles.transform.GetComponent <ParticleSystemRenderer> ().material = confusedMaterial;
        playingParticles.transform.GetComponent <ParticleSystemRenderer> ().material  = playingMaterial;
    }
Exemple #3
0
    void Start()
    {
        alpha         = 0.0f;
        isFadein      = true;
        ocarinaImages = ocarina.GetComponentsInChildren <Image> ();


        birdUIImages = birdUI.GetComponentsInChildren <Image> ();


        makeSound = GameObject.FindWithTag("MusicManager").GetComponent <MakeSound> ();

        SetUIAlphaToZero();
        FadeInOcarina();
    }
 // Start is called before the first frame update
 void Start()
 {
     sound = GetComponent <MakeSound>();
 }