iTween Ignore Scale Time

Here is my code when the game is paused:

Time.timeScale = 0f;

Hashtable ht = new Hashtable();
ht.Add("volume", 0.2f);
ht.Add("time", 0.5f);
ht.Add("ignoretimescale", true);

// down the audio
iTween.AudioTo(Camera.main.gameObject, ht);

But the volume does not adjust… is this a bug? Whats a quick fix? Thanks!

Same may problem, I’ve found a tip solution for that

Here solution https://github.com/machiryo/itween/issues/127
Using Patch file for it at: https://storage.googleapis.com/google-code-attachments/itween/issue-72/comment-6/iTween.cs.delay-ignoreTimeScale.patch

IEnumerator TweenDelay(){
delayStarted = Time.time;

  • yield return new WaitForSeconds (delay);
  • if (useRealTime) { // wait frame-at-a-time for real time to pass (N.b. not yet integrated with Pause())
  • float delayStartedRealTime = Time.realtimeSinceStartup;
  • float resumeTimeRealTime = delayStartedRealTime + delay;
  • while (Time.realtimeSinceStartup < resumeTimeRealTime) {
  • yield return null;
  • }
  • lastRealTime = Time.realtimeSinceStartup; // compensate for delay for real-timers
  • } else {
  • yield return new WaitForSeconds (delay);
  • }
    if(wasPaused){
    wasPaused=false;
    TweenStart();