forked from cgvr/DeltaVR
fix most of FMOD errors in console
This commit is contained in:
@@ -94,6 +94,11 @@ public class FirstPersonOcclusion : MonoBehaviour
|
||||
{
|
||||
if (Listener == null) return;
|
||||
|
||||
if (!AudioOccluded.isValid()) {
|
||||
managedInstances.Remove(AudioOccluded);
|
||||
return;
|
||||
}
|
||||
|
||||
AudioOccluded.isVirtual(out AudioIsVirtual);
|
||||
AudioOccluded.getPlaybackState(out pb);
|
||||
ListenerDistance = Vector3.Distance(transform.position, Listener.transform.position);
|
||||
|
||||
@@ -156,6 +156,11 @@ public abstract class NPCController : MonoBehaviour
|
||||
}
|
||||
|
||||
string key = voiceLineKeys[voiceLineId];
|
||||
if (key.Contains(" | ")) {
|
||||
string[] choices = key.Split(" | ");
|
||||
key = choices[Random.Range(0, choices.Length)];
|
||||
}
|
||||
|
||||
LoadCurve(key); // load RMS data
|
||||
|
||||
currentVoicelineEvent = AudioManager.Instance.PlayDialogue(characterSpecificFolder + "/" + key, gameObject);
|
||||
|
||||
Reference in New Issue
Block a user