Пример #1
0
    void Question_Command(string[] param)
    {
        if (param.Length > 1)
        {
            screen.SetQuestion(param[0], param[1]);

            if ((param[1])[0] != '(')
            {
                OldVSNController.GetInstance().charList.MakeCharTalk(screen.GetTalkingCharName());
            }
        }
        else
        {
            screen.SetQuestion(param[0]);

            if (param[0] == null)
            {
                return;
            }

            if ((param[0])[0] != '(')
            {
                OldVSNController.GetInstance().charList.MakeCharTalk(screen.GetTalkingCharName());
            }
        }
    }
Пример #2
0
    void Choices_Command(string[] param)
    {
        string[] choiceText     = new string[param.Length / 2];
        int[]    choiceWaypoint = new int[param.Length / 2];
        string[] labelNames     = new string[param.Length / 2];
        int      tempIndex      = 0;



        for (int i = 0; i < param.Length; i++)
        {
            if (i % 2 == 0)
            {
                choiceText[tempIndex] = param[i];
            }
            else
            {
                labelNames[tempIndex] = param[i];
                if (waypoints.ContainsKey(param[i]))
                {
                    choiceWaypoint[tempIndex] = waypoints[param[i]];
                }
                else
                {
                    choiceWaypoint[tempIndex] = 0;
                }
                tempIndex++;
            }
        }
        OldVSNController.GetInstance().SetLabelNames(labelNames);
        screen.SetChoices(choiceText, choiceWaypoint);
    }
Пример #3
0
    void AnimAlpha_Command(string[] param)
    {
        int   char_index = OldVSNController.GetInstance().charList.GetCharIdByParam(param[0]);
        float alpha      = float.Parse(param[1]);
        float time       = float.Parse(param[2]);

        CharacterList.GetInstance().AnimateAlpha(char_index, time, alpha);
    }
Пример #4
0
    void Wait_Command(string[] waitTime)
    {
        float time = float.Parse(waitTime[0]);

        screen.EnableDialogBox(false);
        screen.choices.SetActive(false);
        OldVSNController.GetInstance().WaitSeconds(time);
    }
Пример #5
0
    void Anim_Scale_Command(string[] param)
    {
        int   char_index = OldVSNController.GetInstance().charList.GetCharIdByParam(param[0]);
        float scale      = float.Parse(param[1]);
        float time       = float.Parse(param[2]);

        screen.SetScale(char_index, time, scale);
    }
Пример #6
0
    void Move_y_Command(string[] param)
    {
        int   char_index    = OldVSNController.GetInstance().charList.GetCharIdByParam(param[0]);
        float anim_time     = float.Parse(param[1]);
        float destination_y = float.Parse(param[2]);

        screen.SetMovement_y(char_index, anim_time, destination_y);
    }
Пример #7
0
    void Start()
    {
        GameObject gc = GameObject.FindWithTag("GameController");

        if (gc)
        {
            gameController = gc.GetComponent <OldVSNController>();
        }
    }
Пример #8
0
 void ResumeScript_Command(string[] param)
 {
     OldVSNController.ScriptPosition pos = OldVSNController.GetInstance().LastScriptStackEntry();
     OldVSNController.GetInstance().PauseVSN();
     if (param.Length > 0)
     {
         OldVSNController.GetInstance().StartVSNScript(pos.scriptName, param[0]);
     }
     else
     {
         OldVSNController.GetInstance().StartVSNScript(pos.scriptName, pos.scriptLine);
     }
 }
Пример #9
0
    void EndDialog()
    {
        dialogText.text = taggedDialogString;

        talking = false;

        if (OldVSNController.GetInstance().gameState == OldVSNController.GameState.Dialog)
        {
            ShowIndicatorArrow(true);
        }
        OldVSNController.GetInstance().charList.MakeAllCharsStopTalking();
        dialogScreen.EndDialogEffect();
    }
Пример #10
0
 void Say_Command(string[] param)
 {
     OldVSNController.GetInstance().SetDialogState();
     if (param.Length > 1)
     {
         screen.SetDialog(param[0], param[1]);
         OldVSNController.GetInstance().charList.MakeCharTalk(param[0]);
     }
     else
     {
         screen.SetDialog(param[0]);
         OldVSNController.GetInstance().charList.MakeCharTalk(screen.GetTalkingCharName());
     }
 }
Пример #11
0
 void Awake()
 {
     dialogBox.gameObject.SetActive(false);
     instance    = this;
     scriptStack = new List <ScriptPosition>();
 }
Пример #12
0
    void Mirror_Command(string[] param)
    {
        int char_index = OldVSNController.GetInstance().charList.GetCharIdByParam(param[0]);

        screen.MirrorCharacter(char_index);
    }
Пример #13
0
 void FastForwardText()
 {
     OldVSNController.GetInstance().ClickedScreen();
 }
Пример #14
0
 public void SetChoices(string[] text, int[] wp)
 {
     OldVSNController.GetInstance().SetQuestionState(wp);
     dialogBox.SetChoicesText(text);
     ChangeScreenLayout(DialogScreen.ScreenLayout.Question);
 }
Пример #15
0
 void EndScript_Command()
 {
     Debug.Log("Calling endscript");
     OldVSNController.GetInstance().PauseVSN();
     OldVSNController.GetInstance().ClearScriptPositionStack();
 }
Пример #16
0
 void GotoScript_Command(string[] param)
 {
     OldVSNController.GetInstance().PauseVSN();
     OldVSNController.GetInstance().SaveScriptPositionInStack();
     OldVSNController.GetInstance().StartVSNScript(param[0]);
 }
Пример #17
0
 void WaitAnswerConfirm_Command(string[] param)
 {
     screen.EnableDialogBox(false);
     screen.choices.SetActive(false);
     OldVSNController.GetInstance().WaitForValidation(param[0], param[1]);
 }
Пример #18
0
 public void SetQuestion(string text)
 {
     OldVSNController.GetInstance().SetQuestion(text);
     dialogBox.Say(text);
 }