Audiokinetic의 커뮤니티 Q&A는 사용자가 Wwise와 Strata 커뮤니티 내에서 서로 질문과 답변을 하는 포럼입니다. Audiokinetic의 기술 지원팀에게 문의하고 싶으신 경우 지원 티켓 페이지를 사용해주세요.

+1 투표
Hi there, I having quite a lot of trouble with Switches at the moment. I'm finding that my switch continers are not reacting to the changes of switches when playing in game.

I have varifeid all my events are set correctly. When I am not connected, I can simulate all the switch changes in a soundcaster session and all my events react as expected. However, when I connect to the game playing in editor, I can see all the switch changes correctly fireing in the caputure log but the profiler clearly shows that the events are only playing the default switch sound sfx. When I remove the defualt setting from the switch container and regenerate, the events don't play in game or appear in voice graph when connected, though they work fine in the soundcaster as before when unconnected.

I don't know if these are futher clues but; my switch containers are parenting random containers which don't appear in the profiler when connected. In the voice graph I see the correct event, which links to the correct switch container (the object referenced in the event) which links to the sfx played, but misses out the random container in the hirachy. Is this normal behavior for the profilier? The other thing is that when i'm connected and viewing the soundcaster session, I can see the states change appropirotly in tandem with the capture log, but the switches do not change, even though the capture log shows them doing so.

If you know what's going or or where the problem might be, i'd be really greatful if you could point me in the right direction.

Cheers.
General Discussion Dan M. (230 포인트) 로 부터
수정 Dan M. 로 부터

1 답변

+1 투표
 
우수 답변
Hi Dan,

Are you sure that the switch changes are being sent to the same AkObject as the sound events? The scope of a switch is only within a singular game object (AkObject). Hope this helps.
Richard Goulet (5.8k 포인트) 로 부터
선택됨 Benoit S. (Audiokinetic) 로 부터
Brilliant! Yep that solves it. I had assumed they acted like states and were a universal change. Weird they didn't mention that in the 'using switches' documentation :s

Cheers!
Could you please expand on that answer a bit more please? I think I'm having the same issue but I don't understand what you mean when you say "sent to the same AkObject".

I have a switch in Wwise, to which a Playlist container is connected. I expect that if any object changes the switch, the playlist will react accordingly. What does it mean that "the scope of a switch is within a singular game object"?
So all Wwise audio and audio logic plays on an AkGameObject in the game editor (Unity, Unreal etc.) Every sound plays through a component on an object in the game - which tells Wwise where it is playing. Wwise keeps a log of these; it targets sound to whatever your AkEvent plays on. It will generate an AkGameObject at run time if you haven't already got one.

Switches and RTPCs are AkGameObject specific. They will only affect the sounds and events that are playing on the same AkGameObject they are targeted to. Meaning you could have loads of different objects all using the same switch but working independantly.
Oh, I see. Thank you, I had not quite understood that every sound was being played through the object that called the event. It makes sense now.

I guess that means I should never use a Switch for something that is inherently global like music. A State would probably be more intuitive to manage.
Hi Dan, I can understand your answer but, in unreal I really don't know how to target the same AkObject because the Set State blueprint didn't have a pin to enter an Actor into it.
...