Ejemplo n.º 1
0
 void Start()
 {
     scorePlus = gameObject.GetComponent<QuestionScript>();
     score = gameObject.GetComponent<Scores>();
     spawn = gameObject.GetComponent<EnemySpawner>();
     //closestMissle = FindClosestEnemy();
     if(closestMissle)
     {
         target = closestMissle.transform;
     }
 }
Ejemplo n.º 2
0
    void  Start()
    {
        pickup    = gameObject.GetComponent <PickUpScript>();
        score     = gameObject.GetComponent <Scores>();
        spawn     = gameObject.GetComponent <EnemySpawner>();
        scorePlus = gameObject.GetComponent <QuestionScript> ();
        Vector3 randomDirection = new Vector3(Random.Range(0, 0), Random.Range(-359, 359), Random.Range(0, 0));

        //transform.Rotate(randomDirection);
        timing = 0;
    }
Ejemplo n.º 3
0
 void  Start()
 {
     scorePlus = gameObject.GetComponent <QuestionScript>();
     score     = gameObject.GetComponent <Scores>();
     spawn     = gameObject.GetComponent <EnemySpawner>();
     //closestMissle = FindClosestEnemy();
     if (closestMissle)
     {
         target = closestMissle.transform;
     }
 }
Ejemplo n.º 4
0
    void Awake()
    {
        Instance = this;

        questionTemplate_       = TextQuestion.text;
        answersTemplate_        = TextAnswers.text;
        timeLeftTemplate_       = TextTimeLeft.text;
        rewardTemplate_         = TextReward.text;
        revealTemplate_         = TextRevealAnswer.text;
        revealNoAnswerTemplate_ = "Du nåede ikke at svare inden tiden gik!";

        buttonAOriginalPos_ = ButtonA.transform.position;
        buttonBOriginalPos_ = ButtonB.transform.position;
    }
Ejemplo n.º 5
0
        public void Conversation_Follows_Correct_Sequence()
        {
            string expectedName = _fixture.Create <string>();

            var converser = new Mock <IConverser>(MockBehavior.Strict);

            var sequence = new MockSequence();

            converser.InSequence(sequence).Setup(c => c.AskName()).Returns(expectedName);
            converser.InSequence(sequence).Setup(c => c.LineFeed());
            converser.InSequence(sequence).Setup(c => c.SayHello(expectedName));
            converser.InSequence(sequence).Setup(c => c.LineFeed());

            var script = new QuestionScript(converser.Object);

            script.Go();

            converser.Verify(c => c.AskName(), Times.Once);
            converser.Verify(c => c.SayHello(expectedName), Times.Once);
            converser.Verify(c => c.LineFeed(), Times.Exactly(2));
        }
Ejemplo n.º 6
0
Archivo: Main.cs Proyecto: zimpzon/haps
    public void ShowQuestion()
    {
        string q = "Hvor længe kan en sæl holde vejret?";

        QuestionScript.ShowQuestionDialogStatic(q, "80 sekunder", "80 minutter", "1000 XP", QuestionScript.Answer.B, OnQuestionAnswered);
    }
Ejemplo n.º 7
0
 void Start()
 {
     pickup = gameObject.GetComponent<PickUpScript>();
     score = gameObject.GetComponent<Scores>();
     spawn = gameObject.GetComponent<EnemySpawner>();
     scorePlus = gameObject.GetComponent<QuestionScript> ();
     Vector3 randomDirection = new Vector3(Random.Range(0, 0),Random.Range(-359, 359),Random.Range(0, 0));
     //transform.Rotate(randomDirection);
     timing = 0;
 }
Ejemplo n.º 8
0
 void Start()
 {
     myQuestionScript = myQuestionObject.GetComponent <QuestionScript>();
 }