SteamVR

SteamVR

SteamVR Workshop
Customize your SteamVR experience by finding new backgrounds, 3D environments, controllers and base station models.
Learn More
< >
Showing 1-15 of 15 comments
Rectus 13 4 Nov, 2019 @ 12:03am 
You almost have it. First, the sound entity needs to be a point_soundevent instead of ambient_generic. The Sound Event Name property of it determines which soundevent to play.

The way your script is set up, the sound event is named soundname_01 and will play one of the five sound files at random.

The files you need to keep for this are the .wav files in \testnr2\sounds\ and soundevents_addon.vsndevts in \testnr2\soundevents\
Mantas T 1 31 Dec, 2019 @ 12:43am 
thanks for your effort. still no sound.
Made point sound not ambient sound. renamed it to soundname_01, removed unneeded scripts / files...
what else could i be doing wrong?
https://www.flickr.com/photos/maantas/49303532176/in/dateposted-public/
https://www.flickr.com/photos/maantas/49303532251/in/dateposted-public/
https://www.flickr.com/photos/maantas/49303046478/in/dateposted-public/
Rectus 13 31 Dec, 2019 @ 1:43am 
The Sound Event Name propery of the point_soundevent entity needs to match the name of the soundevent, in this case soundname_01 .
Last edited by Rectus; 31 Dec, 2019 @ 1:45am
Rectus 13 31 Dec, 2019 @ 3:25am 
This part needs to be set to soundname_01: https://i.imgur.com/gtP3HGC.png
Mantas T 1 31 Dec, 2019 @ 5:39am 
ok, did that. https://www.flickr.com/photos/maantas/49304082513/in/dateposted-public/
no sound.
but i guess now i would have to import wav files again? cos i had wav files with names 01.wav, 02.wav etc. ?
Rectus 13 31 Dec, 2019 @ 6:06am 
The entity does not reference the sound files directly. A sound event is an abstraction of the actual sound files, sort of how a material is an abstraction of the image textures it uses.

The entity in Hammer only tells the engine to play the sound event soundname_01 in its position. The engine then looks up the sound event form the file, how to play it from the type value, and what files to use from the vsnd_files value.

So in your case you would still need to set the Sound Event Name property to soundname_01 without the .vsnd extension (since it's not the actual sound file). With how your sound event is set up, it would play one of the files randomly every time the sound event is played.

https://i.imgur.com/TxFMRJc.png

If you want to choose which of you sounds 01.wav to 05.wav to play, you would have to make separate sound events for them, no need to reimport the files.

<!-- kv3 encoding:text:version{e21c7f3c-8a33-41c5-9977-a76d3a32aa0d} format:generic:version{7412167c-06e9-4698-aff2-e63eb59037e7} --> { soundname_01 = { type = "destinations.simple_vr" vsnd_files = "sounds/01.vsnd" } soundname_02 = { type = "destinations.simple_vr" vsnd_files = "sounds/02.vsnd" } }

etc.

And then add the soundevent for the right one to the entity:
https://i.imgur.com/zvi4Aor.png
Mantas T 1 31 Dec, 2019 @ 6:31am 
thank you for getting back. removed .vsnd from the Sound Event Name property .. still no go :(
Rectus 13 31 Dec, 2019 @ 6:40am 
Does the sound event show up in the list if you click the magnifying glass on the Sound Event Name property?
Mantas T 1 31 Dec, 2019 @ 7:02am 
actually - no! its not in the list!
https://www.flickr.com/photos/maantas/49304929321/in/dateposted-public/
dam it. so.. does it mean the script is not loaded?
btw - happy new year!
Rectus 13 31 Dec, 2019 @ 7:31am 
Yeah, it might not recompile the script until you run the map though. Try starting the map and it should show up in Hammer if it's set up right.

With the map running you can also try opening the console, and resaving the script. It should print some lines like: Recompiling resource asset: 'soundevents/soundevents_addon.vsndevts'

Or show errors if it failed.

If you haven't used the console before, make sure it's connected to the right port:
https://developer.valvesoftware.com/wiki/SteamVR/Environments/Introduction#Console

And thanks! Still 6 hours to go here.
Mantas T 1 31 Dec, 2019 @ 7:53am 
6 hours? same for me :)
so, tried console, and opened script, resaved it. indeed, there is an error! https://www.flickr.com/photos/maantas/49304668633/in/dateposted-public/
this is the file:
https://www.flickr.com/photos/maantas/49304689488/in/dateposted-public/
Rectus 13 31 Dec, 2019 @ 7:59am 
Ah, looks like it needs commas when you have multiple entries in vsnd_files.
Like:
Law.Fire = { type = "destinations.simple_vr" volume = 0.45 distance_max = "100000" vsnd_files = [ "sounds/weapons/rpg_fire_01.vsnd", "sounds/weapons/rpg_fire_02.vsnd", "sounds/weapons/rpg_fire_03.vsnd", ] }
Mantas T 1 31 Dec, 2019 @ 8:03am 
THERE IS SOUND! thanks a lot!
Rectus 13 31 Dec, 2019 @ 8:06am 
You're welcome. Glad you got it working!
< >
Showing 1-15 of 15 comments
Per page: 1530 50