Ejemplo n.º 1
0
        void castSpell()
        {
            wandHandler.StopTracking();

            // TODO: probably need to run this in a separate thread
            var spell = new IftttStartStopSpell(
                "bslEohHzR8x_HsJ3vWzxub",
                "hue_hedwig_on",
                "hue_spell_off",
                5
            );

            spell.castSpell();

            var cloudBit = new Incendio(DEVICE, AUTHORIZATION, VOLTAGE, DURATION, null, null);
            cloudBit.castSpell();

            sound.PlaySync();
            Close();
        }
Ejemplo n.º 2
0
 private Spell createSpellForResult(int result, double confidence)
 {
     Spell spell = null;
     switch (result)
     {
         case 0:
             spell = new Aguamenti(confidence);
             break;
         case 1:
             spell = new Alohomora(confidence);
             break;
         case 2:
             spell = new ArrestoMomentum(confidence);
             break;
         case 3:
             spell = new Ascendio(confidence);
             break;
         case 4:
             spell = new Descendo(confidence);
             break;
         case 5:
             spell = new Herbivicus(confidence);
             break;
         case 6:
             spell = new Incendio(confidence);
             break;
         case 7:
             spell = new Locomotor(confidence);
             break;
         case 8:
             spell = new Metelojinx(confidence);
             break;
         case 9:
             spell = new Mimblewimble(confidence);
             break;
         case 10:
             spell = new Reparo(confidence);
             break;
         case 11:
             spell = new Revelio(confidence);
             break;
         case 12:
             spell = new Silencio(confidence);
             break;
         case 13:
             spell = new SpecialisRevelio(confidence);
             break;
         case 14:
             spell = new Tarantallegra(confidence);
             break;
         case 15:
             spell = new WingardiumLeviosa(confidence);
             break;
     }
     return spell;
 }
Ejemplo n.º 3
0
        private void castSpell()
        {
            spellCast = true;

            wandHandler.StopTracking();

            var spell = new IftttStartStopSpell(
                "bslEohHzR8x_HsJ3vWzxub",
                "hue_arania_exumai_on",
                "hue_spell_off",
                5
            );

            spell.castSpell();

            var cloudBit = new Incendio(DEVICE, AUTHORIZATION, VOLTAGE, DURATION, null, null);
            cloudBit.castSpell();

            axWindowsMediaPlayer1.Visible = true;
            //playList.appendItem(postMovie);
            pbStrokes.Visible = false;
            shownEnd = true;
            axWindowsMediaPlayer1.currentMedia = postMovie;
        }