Forum rules - please read before posting.

Action list (when hotspot menu turned off) is fired multiple times when fade time > 0

edited May 2015 in Technical Q&A
In the Game Editor > Menu, I put an Action List for Hotspots "when turn on" and "when turn off". The Action Lists are playing sounds as audio feedback when entering or exiting a hotspot menu.

Entering a hotspot menu works correctly, the Action List is invoked and plays the sound. But when exiting a hotspot menu, the Action List "on turn off" is invoked multiple times. That leads - in my case - to a stuttering sound at the beginning when exiting the hotspot.

I found out, that the transition time (Fade) is the problem. If it is set to zero, the problem is gone. But then, the menu has no fade effect. If you set the transition time to 1s, the sound will stutter for 1 second and then play the whole length of the audio. I think, the action list should only be fired once when exiting the hotspot menu.

Comments

  • It should indeed - this sounds like a bug.  Thanks for reporting, I'll look into it.
  • I cannot recreate this in my own testing.  You're using v1.44?  Playing a sound in the "turn off" ActionList only does so once.  Please post a screenshot of your full ActionList.
  • Here https://tresor.it/s#QCgWYk9iM0TfsdxahhABGA  you can find a short mp4 video explaining and demonstrating the problem with fresh downloaded v.1.45. The Action List only contains the action type "Sound - Play" with a sound object that I created with the Game Editor. In the video you can see a second problem: Most of times, I have to press ESC for the menu in terms of getting the sound. Thanks!
  • Thank you - that's an excellent demonstration of the problem.  Others take note!

    I suspect that the ESC issue is because of conflicts with your UFPS.  I will have to look into that.

    As for the main issue, what you've given me should be enough now for me to recreate it.  I'll let you know if I need anything else.
  • Try this: open up Menu.cs (it's in Assets/AdventureCreator/Scripts/Menu/Menu classes) and change line 1223:

    if
     (actionListOnTurnOff != null)

    to read:

    if (actionListOnTurnOff != null && !isFading)
  • edited May 2015
    Yes, this removes the fading problem, thank you very much! In my opinion, this is the desired behaviour. So I would be very glad to see it in one of the next bugfix releases.

    Eventually you could also have a look at the problem, that the Action-Lists are triggered when klicking the left mouse button while staying in the hotspot area? I think this is not desired too. Perhaps the whole function "TurnOff" should not be fired when staying in the hotspot area?

    Perhaps the same reason makes the flickering of Hotspot and Inventory Label when pressing the InteractionA key (or the mouse button)?
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.