Esempio n. 1
0
 void OnTriggerEnter(Collider other)
 {
     if (other.gameObject == playerObject)
     {
         narrationText.DisplayText(textToShow, timeToShow);
     }
     Destroy(gameObject);
 }
Esempio n. 2
0
    public override void Interact(GameObject user)
    {
        base.Interact(user);
        narrationText.DisplayText("Office Hours are over.", 5);

        PlayerEngine ps = user.GetComponent <PlayerEngine>();

        if (ps)
        {
            ps.WinGame();
        }
    }