undeadslayer Posted July 3, 2021 Posted July 3, 2021 Hi everybody, I'm working on a single player map and I'm having some trouble with it. I wanted to add sound files to my doors in the map. I attached the desired sound to the brushes but for some reason the game won't play it in game. Is there something I'm doing wrong?
NAB622 Posted July 3, 2021 Posted July 3, 2021 How did you attach the sound to the door? Also, what format is the file?
undeadslayer Posted July 3, 2021 Author Posted July 3, 2021 NAB622, I selected the door and pressed the n key to bring up the entities and the I pressed the ... button next to the sound bar. I am using a .wav sound file.
NAB622 Posted July 3, 2021 Posted July 3, 2021 When you try to play the sound (Or maybe when the map loads), an error should be listed in the game console - do you see one by chance? I ask because two reasons - some versions of Radiant will give you a corrupt/incorrect path when you add a sound using this method. It might be worth manually checking to be sure it has the right path. Second, wav files need to be mono, and I think they need to be a specific bit depth and sample rate too, but I could be wrong on that. Either way, the console should have an error that tells you what is wrong.
undeadslayer Posted July 3, 2021 Author Posted July 3, 2021 Unfortunately there is no error in the game's console, at least not popping up that is.
undeadslayer Posted July 3, 2021 Author Posted July 3, 2021 @NAB622, I just tried the manual method and it is still not playing the sound.
NAB622 Posted July 4, 2021 Posted July 4, 2021 Interesting. What is the exact path of the sound, as listed in Radiant? Or, better yet, do you have a test PK3 I could look at?
undeadslayer Posted July 4, 2021 Author Posted July 4, 2021 @NAB622, the path is C:Program Files(x86)/ LucasArts/ Star Wars Jedi Knght Jedi Academy/ GameData/ Base/ Sounds.
NAB622 Posted July 4, 2021 Posted July 4, 2021 If that is the path that is listed in Radiant, it is giving you the wrong path. It needs to be relative to the base folder. Here's an example sound from a trigger_multiple entity: key: noise value: sound/movers/switches/switch2.mp3 If you change your path accordingly, the sound file should load.
undeadslayer Posted July 5, 2021 Author Posted July 5, 2021 @NAB622, could you explain in more detail? I'm still kind of new to this.
Circa Posted July 6, 2021 Posted July 6, 2021 On 7/4/2021 at 9:47 PM, undeadslayer said: @NAB622, could you explain in more detail? I'm still kind of new to this. He means the path to the sound should be relative to your PK3 file, not your computer. Or if you're using a sound that is already in the game, relative to the path in the assets0.pk3. It should look similar to his example he gave when you edit that entity. Also keep in mind you should be using "soundset" for doors unless you are using a trigger_multiple or target_speaker for it. This tutorial explains the basics of doors and has the sound portion: https://jkhub.org/mapping/richdiesal/Brushes201_Lesson_5_Doors_files/br201lsn5.htm To quote: To look up the soundsets you can use for doors, open up the sound/sound.txt file and do a text search for... well, the word "door." Add the key soundset and the value for the soundset you want. I will be using large_door for mine. This also shows the soundset key and explains how to do doors in SP fairly simply: https://jkhub.org/forums/topic/5149-lets-map-singleplayer/?do=findComment&comment=76650
MagSul Posted July 7, 2021 Posted July 7, 2021 I made a working example of a door using a switch to open that produces that sound when you use the switch. Just "/devmap example" to a pre-compiled version in-game, or open the included example_door.map to take a look at how it was done. https://www.dropbox.com/s/btamb0l7h1tvygh/Example.zip?dl=0 NAB622 likes this
undeadslayer Posted July 8, 2021 Author Posted July 8, 2021 @Circa and @MagSul, thanks for the help the doors now have a sound attached to it. The sound problem that I had is not the only problem with the map. I messed up a later version the map when I attempted to add in a tram to the map. I had load in my backup for the map and oddly lost a texture for my doors in game, radiant still has the texture on it. I'll post something in this from when I need more help. MagSul likes this
undeadslayer Posted July 9, 2021 Author Posted July 9, 2021 Need some more help. I put a couple of secret areas in the map. One of them is not working properly, some assistance would be appreciated.
NAB622 Posted July 9, 2021 Posted July 9, 2021 What exactly isn't working about the secret area? What is it doing wrong? What is it supposed to do?
undeadslayer Posted July 10, 2021 Author Posted July 10, 2021 @NAB622, It's supposed say: "Secret Area!" and also play a sound. The second secret area did it just fine. The only thing that I can think of that might be causing the problem is that the first secret area the player has to activate a switch to open the secret area.
MagSul Posted July 11, 2021 Posted July 11, 2021 My preferred method for secret areas is just to right-click the grid in GTKRadiant and place a target_secret anywhere inside of your geometry. Then, create a system/trigger brush and set it as a trigger_once. Connect the trigger_once to the target_secret and you're done! When the player then walks through the trigger, the secret area notification is triggered.
undeadslayer Posted July 11, 2021 Author Posted July 11, 2021 @MagSul That's exactly what I did and it's still not registering with the game. Do I need to number the secret areas so that the game does not get confused?
MagSul Posted July 11, 2021 Posted July 11, 2021 On a "target_secret" entity, you should set the key as "count" and the value to the total number of secrets on all of them. That said, I didn't do it on a recent map of my own and it still worked, which implies that your issue is being caused by something else. I can take a look at the map directly, if you want to send it over in a DM.
undeadslayer Posted July 11, 2021 Author Posted July 11, 2021 @MagSul is there a way I can send a zip in a post or does this site not allow that?
MagSul Posted July 11, 2021 Posted July 11, 2021 You could .zip the file and create a share link from a cloud storage service such as Dropbox, Google Drive and so on. There're a few free options out there and it's always worth backing up things like maps online - you never know what could happen!
undeadslayer Posted July 11, 2021 Author Posted July 11, 2021 @MagSul Would I need to make an account with either of those?
Circa Posted July 11, 2021 Posted July 11, 2021 5 minutes ago, undeadslayer said: @MagSul Would I need to make an account with either of those? Use WeTransfer.
undeadslayer Posted July 11, 2021 Author Posted July 11, 2021 @Circa I do have gmail account I just haven't used the drive before.
NAB622 Posted July 12, 2021 Posted July 12, 2021 Just another thought - make sure each secret area is using a unique trigger_once. Triggers can have multiple brushes, and if you accidentally put both brushes in the same trigger, only the first secret you hit will work. MagSul likes this
Recommended Posts