Bugfix
Small bug prevented text from showing without sound
This commit is contained in:
parent
9f9dedba98
commit
505584b91e
3 changed files with 4 additions and 5 deletions
|
@ -28,12 +28,11 @@ namespace SimpleTools.DialogueSystem {
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool Dialogue(Dialogue dialogue) {
|
public bool Dialogue(Dialogue dialogue) {
|
||||||
return Dialogue(dialogue, "");
|
return Dialogue(dialogue, string.Empty);
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool Dialogue(Dialogue dialogue, params string[] sounds) {
|
public bool Dialogue(Dialogue dialogue, params string[] sounds) {
|
||||||
if (sounds != null)
|
dialogueVertexAnimator.SetAudioSourceGroup(sounds);
|
||||||
dialogueVertexAnimator.SetAudioSourceGroup(sounds);
|
|
||||||
|
|
||||||
if (!talking) {
|
if (!talking) {
|
||||||
sentences.Clear();
|
sentences.Clear();
|
||||||
|
|
|
@ -216,7 +216,7 @@ namespace SimpleTools.DialogueSystem {
|
||||||
if (Time.unscaledTime - lastDialogueSound > timeUntilNextDialogueSound) {
|
if (Time.unscaledTime - lastDialogueSound > timeUntilNextDialogueSound) {
|
||||||
timeUntilNextDialogueSound = UnityEngine.Random.Range(0.02f, 0.08f);
|
timeUntilNextDialogueSound = UnityEngine.Random.Range(0.02f, 0.08f);
|
||||||
lastDialogueSound = Time.unscaledTime;
|
lastDialogueSound = Time.unscaledTime;
|
||||||
if (audioSourceGroup != null)
|
if (audioSourceGroup[0] != string.Empty)
|
||||||
AudioManager.AudioManager.instance.PlayRandomSound(audioSourceGroup);
|
AudioManager.AudioManager.instance.PlayRandomSound(audioSourceGroup);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "com.geri.simpletools",
|
"name": "com.geri.simpletools",
|
||||||
"version": "1.2.0",
|
"version": "1.2.1",
|
||||||
"displayName": "Simple Tools",
|
"displayName": "Simple Tools",
|
||||||
"description": "This package contains simple tools to use in your project.",
|
"description": "This package contains simple tools to use in your project.",
|
||||||
"unity": "2018.4",
|
"unity": "2018.4",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue