Beispiel #1
0
    public IEnumerator EndReadBoard(TriggerHandler_Board board)
    {
        playerTextBalloon.GetComponentInChildren <Text>().text = null;
        RectTransform balloonRect = playerTextBalloon.transform.GetChild(0).GetComponent <RectTransform>();
        float         width       = balloonRect.rect.width;
        float         height      = balloonRect.rect.height;
        Vector2       initialSize = new Vector2(width, height);

        for (int i = 0; i < 50; i++)
        {
            initialSize.x        -= 5f;
            balloonRect.sizeDelta = initialSize;
            yield return(new WaitForSeconds(0.01f));
        }
        board.isReading = false;
        playerTextBalloon.SetActive(false);
        yield return(null);
    }
Beispiel #2
0
 public IEnumerator ContinueReadBoard(TriggerHandler_Board board)
 {
     playerTextBalloon.GetComponentInChildren <Text>().text = board.textInBoard[board.keyCounter];
     yield return(null);
 }