Exemple #1
0
    private void SetNarrativeDialogue(SpeakerUIController _activeSpeakerUI, SpeakerUIController _inactiveSpeakerUI, string _text)
    {
        activeSpeakerUI           = _activeSpeakerUI;
        _activeSpeakerUI.Dialogue = _text;
        _activeSpeakerUI.Show();

        if (_activeSpeakerUI.dialoguePanelGO != enabled)
        {
            AM.PlayConsistentOneShot(panelOpenCloseSound, panelOpenCloseVolume);
        }

        _inactiveSpeakerUI.Hide();

        if (_activeSpeakerUI.dialoguePanelGO == enabled)
        {
            AM.PlayConsistentOneShot(panelOpenCloseSound, panelOpenCloseVolume);
        }

        _activeSpeakerUI.Dialogue = "";

        if (typeCoroutine != null)
        {
            StopCoroutine(typeCoroutine);
        }

        typeCoroutine = TypeWritterEffect_N(_text, _activeSpeakerUI);
        StartCoroutine(typeCoroutine);
    }
Exemple #2
0
    private void SetDialogue(SpeakerUIController activeSpeakerUI, Character character, string text, Position position, Emote emote)
    {
        activeSpeakerUI.Speaker = character;
        switch (position)
        {
        case Position.LEFT:
            activeSpeakerUI.SetLeft();
            break;

        case Position.RIGHT:
            activeSpeakerUI.SetRight();
            break;

        case Position.CENTER:
            activeSpeakerUI.SetCenter();
            break;

        default:
            activeSpeakerUI.SetLeft();
            break;
        }
        switch (emote)
        {
        case Emote.ANGRY:
            activeSpeakerUI.SetPortrait(character.angryPortrait);
            break;

        case Emote.CONFUSED:
            activeSpeakerUI.SetPortrait(character.confusedPortrait);
            break;

        case Emote.HAPPY:
            activeSpeakerUI.SetPortrait(character.happyPortrait);
            break;

        case Emote.UNHAPPY:
            activeSpeakerUI.SetPortrait(character.unhappyPortrait);
            break;

        case Emote.SAD:
            activeSpeakerUI.SetPortrait(character.sadPortrait);
            break;

        case Emote.SILLY:
            activeSpeakerUI.SetPortrait(character.sillyPortrait);
            break;

        default:
            activeSpeakerUI.SetPortrait(character.portrait);
            break;
        }
        activeSpeakerUI.Show();
        activeSpeakerUI.Dialogue = "";
        StopAllCoroutines();
        StartCoroutine(EffectTypewriter(text, activeSpeakerUI));
    }
Exemple #3
0
    private void SetNarrativeMonologueDialogue(SpeakerUIController _activeSpeakerUI, string _text)
    {
        activeSpeakerUI           = _activeSpeakerUI;
        _activeSpeakerUI.Dialogue = _text;
        _activeSpeakerUI.Show();

        _activeSpeakerUI.Dialogue = "";

        if (typeCoroutine != null)
        {
            StopCoroutine(typeCoroutine);
        }

        typeCoroutine = TypeWritterEffect_N(_text, _activeSpeakerUI);
        StartCoroutine(typeCoroutine);
    }