コード例 #1
0
    // Update is called once per frame
    void Update()
    {
        if (!isActive)
        {
            return;
        }

        //theText.text = textLines[currentLine];

        if (Input.GetKeyDown(KeyCode.Space))
        {
            if (!isTyping)
            {
                currentLine += 1;
                if (currentLine > endAtLine)
                {
                    DisableTextBox();
                    ActivateTextAtLine a = FindObjectOfType <ActivateTextAtLine>();
                    //a.waitForPress = true;
                }
                else
                {
                    CheckSpeakerName();

                    StartCoroutine(TextScroll(textLines[currentLine]));
                }
            }
            else if (isTyping && !cancelTyping)
            {
                cancelTyping = true;
            }
        }
    }
コード例 #2
0
    int gapX, gapY; //use to determine gap between icons

    // Start is called before the first frame update
    void Start()
    {
        callingTheText = FindObjectOfType <ActivateTextAtLine>();
        theTextBox     = FindObjectOfType <TextBoxManager>();
        List <GameObject> backpack = new List <GameObject>();

        initPos    = new Vector2(backpackBG.transform.position.x - initX, backpackBG.transform.position.y - initY);
        spaceToUse = gameObject.GetComponent <PlayerTriggers>().spaceToUse;
    }
コード例 #3
0
    // Use this for initialization
    void Start()
    {
        activateTextAtLine = GetComponent <ActivateTextAtLine>();

        if (stateFile != null)
        {
            stateLines = (stateFile.text.Split('\n'));
        }

        for (int i = 0; i < stateLines.Length; i++)
        {
            //stateDict.Add(stateLines[i],
        }
    }
コード例 #4
0
ファイル: PickUpFade.cs プロジェクト: WomTarp/VGD2016-Team10
 void Start()
 {
     aText = GetComponentInChildren<ActivateTextAtLine>();
     gItem = GetComponentInChildren<GetItem>();
     entered = false;
 }
コード例 #5
0
ファイル: SalScript.cs プロジェクト: Nerelod/Unyte
 // Use this for initialization
 void Start()
 {
     anim          = GetComponent <Animator>();
     activatedText = GetComponent <ActivateTextAtLine>();
 }