Пример #1
0
//	public void submit(){
//
//		y = ansslot.GetComponentInChildren<Text> ().text ;
//		//Debug.Log (ansslot.GetComponentInChildren<Text> ().text);
//
//		if (y == gamesql.checker) {
//			correctAttack ();
//		} else {
//			wrongAttack();
//		}
//
//	}


    public void wrongAttack()
    {
//		gamesql.timer = 1f;
        //Fire when option is choosen.
        missile = missile.GetComponent <Missile> ();
        source.PlayOneShot(fly);
        missile.createShot();

        resetOpt = resetOpt.GetComponent <ResetOption> ();
        resetOpt.reset();

        gamesql.activation();
    }
Пример #2
0
/*------------------------------------PLAYER1 ATTACK--------------------------------------------------------*/

	public void P1CorrectAttack(){

		//Fire when option is choosen. 
		fireBall = fireBall.GetComponent<FireBall> ();
		source.PlayOneShot(fireballsound);
		fireBall.createShot ();

		//reset the options back to original place. 
		resetOpt = resetOpt.GetComponent<ResetOption> ();
		resetOpt.reset ();
		resetOpt2 = resetOpt.GetComponent<ResetOption2> ();
		resetOpt2.reset ();
		
		gamesqlM.activation();
	}
Пример #3
0
	public void P1WrongAttack(){
		//Fire when option is choosen. 
		missile = missile.GetComponent<Missile> ();
		source.PlayOneShot(fly);
		missile.createShot ();

		//reset the options back to original place. 
		resetOpt = resetOpt.GetComponent<ResetOption> ();
		resetOpt.reset ();
		resetOpt2 = resetOpt.GetComponent<ResetOption2> ();
		resetOpt2.reset ();
		
		gamesqlM.activation();
	}