Wwise and Unity: Switches controlling footsteps, by Cujo Sound

  Рет қаралды 3,700

Cujo Sound

Cujo Sound

Күн бұрын

Пікірлер
@zacharydejean1912
@zacharydejean1912 2 жыл бұрын
Hi Bjorn, firstly I just want to say a big thank you for providing these Unity/Wwise tutorial videos. I have certainly learned a lot from them and they have helped me get through my project that I am developing for uni. I have a question - in my project there is a multistory building where the majority of the flooring is wood, so i have covered the whole area with a large box collider to trigger the appropriate footstep sounds. However, there are random rugs/carpets placed around the interior, so I have placed mini colliders (inside the large collider) over these said rugs to trigger a different footstep sound. Interestingly, on some occasions when testing, it'll trigger the rug sounds and back to regular wood sounds as you exit the mini colliders (which is the goal), but other occasions the rug colliders wont trigger the appropriate sounds. Is there a way to consistently trigger the appropriate footstep sounds in this situation through programming or is it simply a case of positioning multiple colliders over the wooden floors and rugs instead of having multiple mini colliders inside of a large collider?
@CujoSound
@CujoSound 2 жыл бұрын
Does this happen randomly or on a specific collider? Which can be reproduced then ? and thank you for the kind words. :)
@zacharydejean1912
@zacharydejean1912 2 жыл бұрын
@@CujoSound thank you for the swift response! It is a random occurrence. One play-through it'll play wood to rug footsteps as I enter the rug collider and back to wood as I leave. But on another play-through it'll continue playing wooden footsteps, regardless of entering the rug collider or not. It is random and fairly inconsistent.
@CujoSound
@CujoSound 2 жыл бұрын
@@zacharydejean1912 and its set to on enter? Not to OnStay?
@zacharydejean1912
@zacharydejean1912 2 жыл бұрын
@@CujoSound I apologize for forgetting to mentioning this in my original comment - so I entered a 3rd function to the material script (OnTriggerStay) to play the enter switch. Reason why I added this is because some of the rugs were overlapping with each other and moving from one rug to another (rug collider to another rug collider) WITHOUT the additional script function would not trigger the rug footstep sounds. ADDING the OnStay function has solved this issue but has presented me with another, as specified before. Again, sorry if I haven't explained my issue 100% clearly ha ha
@CujoSound
@CujoSound 2 жыл бұрын
​@@zacharydejean1912 Right- but then I would assume that your OnTriggerStay is also on the wood one right? are they in the same switch container as the wood one? I'd assume that what happens is that, because it is Stay, then it overwrites the switch. If you try with being just OnTriggerEnter and Exit, does it still do this? You could have two switches though - one for main material, which is wood - and then set the rug to a different one, that could be a solution as well - because if they are in the same switch container (Wood, rug, dirt, etc.) then it can only have one value at a time.
@thedimasss
@thedimasss 5 жыл бұрын
Very nice, thank you!
@mesterolsen
@mesterolsen 3 жыл бұрын
So, I followed this tutorial and it works very good, so thank you for that! However, I tried to create several box colliders or sphere collider that where overlapping and found that if I exit a collider and enter a new one that is overlapping with the previous one, it only triggers the exit switch. Is there anyway to make it work for overlapping colliders as well? If we wanted grass - sounds for an area that required multiple overlapping colliders and dirt - sound for when you exited that area?
@CujoSound
@CujoSound 3 жыл бұрын
Are you sure that whatever it triggers is allowed to have multiple values? I mean, if you enter one while exit another and the value indicating which material is only allowed to have one it would only contain the latest one. If you only have one switch then it can only have one value. That could be one thing, but else I think it could be that you should try with more rough overlaps, so that they are not barely touching but really overlapping (haven't seen your setup, so I can't know obviously)
@patrizio.sound.london
@patrizio.sound.london 4 жыл бұрын
Very useful man! Would be great to have some tutorial about how to implement the jumping and landing sound in the code.
@CujoSound
@CujoSound 4 жыл бұрын
That should be fairly doable.
@patrizio.sound.london
@patrizio.sound.london 4 жыл бұрын
@@CujoSound what d'you mean? implementing the sound or doing the tutorial? :D
@CujoSound
@CujoSound 4 жыл бұрын
@@patrizio.sound.london doing the tutorial. :)
@patrizio.sound.london
@patrizio.sound.london 4 жыл бұрын
@@CujoSound lovely. Great contents mate. I'm starting to learn how the code works in unity/wwise and I got stucked every 3 minutes. lol
@MikeBAudio
@MikeBAudio 6 жыл бұрын
Yo Bjorn, Thanks for the vid! How do you get 2 project explorers up in Wwise? Love the look of that workflow :)
@CujoSound
@CujoSound 6 жыл бұрын
Ctrl - shift 1,2,3,4,5 ;) Or right click any item and say show in group 1,2, 3,4,5. If that group window isn't open already it opens it.
@MikeBAudio
@MikeBAudio 6 жыл бұрын
@@CujoSound Cheers ;)
@CujoSound
@CujoSound 6 жыл бұрын
Select sync group I think it's called. :) That's how you can always just click anything and have it take you straight there.
@CujoSound
@CujoSound 6 жыл бұрын
@@MikeBAudio absolutely no problem :)
@MikeBAudio
@MikeBAudio 6 жыл бұрын
@@CujoSound Yeah being able to have the audio AND event tab onscreen is a game changer.... thanks again Bjorn
@Eliazer
@Eliazer Жыл бұрын
Does anyone else get the following error when the switch is suppose to change (I registered the game object in the animation script)? Timestamp Type Description Object Name Game Object Name Object ID Game Object ID Scope 0:10:52.618 Error Invalid parameter in_GameObj in function call AK::SoundEngine::RegisterGameObj 0:10:52.618 Error Dead game object ID used in function SetSwitch. This object was unregistered with AK::SoundEngine::UnregisterGameObj some time prior this call. Thanks
@supermazy22
@supermazy22 3 жыл бұрын
Thanks for the video, love watching your content! I'm sure I've set everything up correctly, however my switch isn't triggering - in Wwise it loads the default switch group (in my case "Grass"), but when I walk into my collider, nothing happens in Wwise and it doesn't switch to the "Stone" I'd like to work. I'm using the 3D Game Kit in Unity and so have been using "Ellen" as my substitute for the 3rd Person Controller, which I believe is also correct. I've tried using the camera instead of Ellen, but it still doesn't work. Any ideas on what could be the problem? When I turn my debug on, it also gives no feedback, as though the collider isn't even there. I'm stumped haha
@CujoSound
@CujoSound 3 жыл бұрын
That's difficult, but if the debug doesn't trigger, check for typos in the tag and other things first. First I thought that the switch wasn't set, but if the debug doesn't work then it's something about the object colliding with the collider, so probably the tag ? Put in the debug earlier, at OnTriggerEnter as the first thing.
@supermazy22
@supermazy22 3 жыл бұрын
@@CujoSound Thanks so much for your quick reply! I re-watched the video, I went back into my script and my Wwise Project and double and triple checked everything and everything seems to line up properly, so I'm really not sure what the issue is. I noticed that "Ellen" in my scene was untagged, so I gave her the "Player" tag, and then double checked again, but still to no avail. Wwise and Unity are both still not recognising any change in switch - how confusing! If you'd like I can copy and paste the script I've written so you can check it yourself, I'm new to all this so I could still be missing something. Thanks again for your swift response, I really appreciate it.
@CujoSound
@CujoSound 3 жыл бұрын
@@supermazy22 Sure go ahead :)
@TheGeorge215
@TheGeorge215 3 жыл бұрын
@@CujoSound Hey! Did you end up finding a fix for Matthew? I'm using the 3D Game Kit as well and I'm struggling with the same problem.
@CujoSound
@CujoSound 3 жыл бұрын
@@TheGeorge215 I didn't. But it will definitely be the collider not triggering because of some sort of filtering.
@systematic-sound
@systematic-sound 6 жыл бұрын
TADAAAA! ^^
@FERZiNANDoS
@FERZiNANDoS 2 жыл бұрын
Hi Bjørn! Thanks for your wonderful tutorials! I am new to Unity and am currently solving the problem of assigning sounds footsteps to terrain layers. Found an interesting solution kzbin.info/www/bejne/ipOWf3qBnNZkqpo But since I'm not a programmer, I can't integrate this solution into Wwise. It would be great if you could make a video on this topic.Thanks a lot!
Wwise & Unity - Quick Camera and Listener Rotation Fix.
3:40
Cujo Sound
Рет қаралды 1,3 М.
Сестра обхитрила!
00:17
Victoria Portfolio
Рет қаралды 906 М.
Wwise: Episode 3 - 99 ways to footsteps - Switches
12:29
Cujo Sound
Рет қаралды 2,6 М.
Dynamic Footsteps! : For Terrains and Imported Meshes (Unity3D)
20:29
Gamedev In-Depth | How I Implement a New Feature
19:20
ThinMatrix
Рет қаралды 65 М.
Why has Black & White Been Abandoned? - Noclip Greatest Hits
28:44
Noclip - Video Game Documentaries
Рет қаралды 730 М.
The New Outlook is TERRIBLE
20:19
Chris Titus Tech
Рет қаралды 105 М.
Wwise & Unreal | Adding 3D Audio With Attenuation
17:21
Scott Game Sounds
Рет қаралды 9 М.
AAA Wwise projects - How to get started on the music system.
11:08
Unity's John LEMON: How to implement your sounds using Wwise
13:30
Máté Moldován
Рет қаралды 6 М.
The Ultimate Guide for Physics in Game Development!
1:04:41
Will Hess
Рет қаралды 142 М.