0
0

Hello, i can’t solve this problem, i’ve made FMOD parameter “health” (range 0-100), how can i link it to Player’s Health in Unity, so when Player’s health drops below 30% it will trigger FMOD parameter “Health” with simple low filter cutoff.
I mean logically there is a way to create dialog between FMOD Health(0-100) parameter and Player Health in Unity(0-100), but how?

  • You must to post comments
0
0

An example could be as basic as this:

 [FMODUnity.EventRef]    public string eventRef;
 FMOD.Studio.EventInstance instance;
 FMOD.Studio.ParameterInstance health;

 void Start ()
 {
      instance = FMODUnity.RuntimeManager.CreateInstance(eventRef);
      instance.getParameter("health", out health);
 }

 void Update ()
 {
       health.setValue(playerHealth);   
 }
  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.