Esempio n. 1
0
    // Use this for initialization
    void Start()
    {
        GamePause.pauseGame();

        name.GetComponent <TextMesh> ().text     = "You";
        dialogue.GetComponent <TextMesh> ().text = main1;
    }
Esempio n. 2
0
    // Use this for initialization
    void Start()
    {
        GamePause.pauseGame();
        DialogSystem.character[] cArr =
        {
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.PLAYER,
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.PLAYER,
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.PLAYER,
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.PLAYER,
            DialogSystem.character.VOLDEMORT,
            DialogSystem.character.VOLDEMORT
        };

        string[] dialog = new string[] {
            "Finally, get you back to here...",
            "Oh, I am sorry, does it hurt?",
            "I am fine... Just feel sleepy...",
            "Why did you attack me?!",
            "I was controlled by the boss... That was not what I want",
            "Your boss? Who he is? Take me to him!",
            "I can't hold long... listen!",
            "Use my magic ward to unlock the sundial, he is under there!",
            "Magic? Who are you?\nHow can you know magic?",
            "I was the magic club chairman long time ago...",
            "Remember Mobiliarbus...Mobiliarbus..."
        };

        conversation(cArr, dialog, 1);
    }
Esempio n. 3
0
 override public void  onDialogFinish(int id, int selection)
 {
     //selection -1: No selection carried out 0; false or no 1: true or yes
     Debug.Log("Dialog with id " + id + "has finished with selection result " + selection);
     if (id == 732)
     {
         GamePause.pauseGame();
         AutoFade.LoadLevel("end_scene", 1f, 1f, Color.black);
     }
 }
 override public void  onDialogFinish(int id, int selection)
 {
     //selection -1: No selection carried out 0; false or no 1: true or yes
     Debug.Log("Dialog with id " + id + "has finished with selection result " + selection);
     if (id == 632)
     {
         GamePause.pauseGame();
         GlobalValues.BattleData.battleBackgroundID = 5;
         GlobalValues.BattleData.numOfMonsters      = 1;
         GlobalValues.BattleData.monsterID          = new int[] { 7 };
         GlobalValues.BattleData.isFinalStage       = true;
         AutoFade.LoadLevel("battle", 0.5f, 0.5f, Color.black);
     }
 }
Esempio n. 5
0
    IEnumerator  wait1Sec()
    {
        GamePause.pauseGame();
        yield return(new WaitForSeconds(0.7f));

        GamePause.continueGame();
        if (!SaveLoadSystem.getInstance().labSceneStateArr [(int)SaveLoadSystem.LabSceneState.BEGANDIALOG])
        {
            StartCoroutine("startBeginningDialog");
        }
        else
        {
            StartCoroutine("startLoopHint1");
        }
    }
Esempio n. 6
0
 public void showPanel()
 {
     GamePause.pauseGame();
     moveToCamera();
     gameObject.SetActiveRecursively(true);
 }
Esempio n. 7
0
    void CreateDialog()
    {
        Debug.Log("Creating Dialogue");


        for (int i = 0; i < nameString.Length; i++)
        {
            switch ((int)nameString [i])
            {
            case 0:
                cnameString.Enqueue("You");
                break;

            case 1:
                cnameString.Enqueue("Principal");
                break;

            case 2:
                cnameString.Enqueue("Cleaning Lady");
                break;

            case 3:
                cnameString.Enqueue("Dembeater1");
                break;

            case 4:
                cnameString.Enqueue("Dembeater2");
                break;

            case 5:
                cnameString.Enqueue("The (girl)?");
                break;

            case 6:
                cnameString.Enqueue("Voldemort");
                break;

            case 7:
                cnameString.Enqueue("DumJack");
                break;

            case 8:
                cnameString.Enqueue("System");
                break;
            }
        }
        dialog_counter = nameString.Length;

        foreach (string s in dialogString)
        {
            cdialogString.Enqueue(s);
        }

        Vector3 position = Camera.mainCamera.gameObject.transform.position;

        position.y -= 3;
        position.z -= 3.5f;
        if (Application.loadedLevelName == "SecretChamberBefore" || Application.loadedLevelName == "SecretChamberAfter" || Application.loadedLevelName == "sundial")
        {
            Debug.Log("Detect 2D scene by DS");

            position.x     = 0;
            position.z     = 0;
            dialogInstance = Instantiate(dialogPrefab, position, Quaternion.Euler(0, 0, 0)) as GameObject;
        }
        else
        {
            dialogInstance = Instantiate(dialogPrefab, position, Quaternion.Euler(90, 0, 0)) as GameObject;
        }
        if (!option_Mode)
        {
            dialogInstance.transform.GetChild(5).gameObject.SetActive(false);
        }
        if (!option_Mode)
        {
            dialogInstance.transform.GetChild(6).gameObject.SetActive(false);
        }

        setPic();
        dialogInstance.transform.localScale -= new Vector3(0.2F, 0.2F, 0.8F);
        isClick = true;

        /*
         *      for (int i=0; i<num; i++) {
         *              if (isClick) {
         *                              dialogbg = Instantiate (dialogpf, new Vector3(0,0,-30), Quaternion.identity)as GameObject;
         *                              dialogbg.transform.GetChild (1).GetComponent<TextMesh> ().text = name;
         *                              dialogbg.transform.GetChild (2).GetComponent<TextMesh> ().text = alldialog [0];
         *                              waitForClick = true;
         *                              isClick=false;
         *              }
         * }*/
        dialogisOn   = false;
        waitForClick = true;
        GamePause.pauseGame();
    }