boobzooka Posted April 19, 2022 I have a disco level where I have dance floors and when I get close to them I want the music to get more and more clear but I have no clue how to do it, no clue on the script or what to do with the actor, here is a screenshot of the idea, where I want to place the actor for the music to play at those spots specifically, the white arrow will show you. Thank you for your time guys. 0 Quote Share this post Link to post
kwc Posted April 20, 2022 (edited) What map format are you working with/what port(s) are you targeting? Edited April 20, 2022 by kwc 0 Quote Share this post Link to post
boobzooka Posted April 20, 2022 10 hours ago, kwc said: What map format are you working with/what port(s) are you targeting? Sorry for the late response UDMF GZdoom and Zandronum, 0 Quote Share this post Link to post
Kan3 Posted April 20, 2022 You could then try playing with PlaySound attenuation parameter in a script. Try setting it to 0.1 and see how far you can hear it. 0 Quote Share this post Link to post
boobzooka Posted April 20, 2022 7 hours ago, Kan3 said: You could then try playing with PlaySound attenuation parameter in a script. Try setting it to 0.1 and see how far you can hear it. What script though 0 Quote Share this post Link to post
Kan3 Posted April 20, 2022 A question first: are you using the music you want to play in this way as a music track for the whole map or you're using it separately in a ZDoom thing in that room? After that: basically you just have to create an OPEN script in the script editor and use the function PlaySound(all of the parameters needed here); like the wiki shows. You then give a thing inside the sector you want a tid and write this as the first parameter of the PlaySound function. 0 Quote Share this post Link to post
boobzooka Posted April 20, 2022 7 minutes ago, Kan3 said: A question first: are you using the music you want to play in this way as a music track for the whole map or you're using it separately in a ZDoom thing in that room? After that: basically you just have to create an OPEN script in the script editor and use the function PlaySound(all of the parameters needed here); like the wiki shows. You then give a thing inside the sector you want a tid and write this as the first parameter of the PlaySound function. Okay so this is the script I made and here is the thing that is on the map. The script says unknown script though, also this is the SNDINFO 0 Quote Share this post Link to post
boobzooka Posted April 20, 2022 10 minutes ago, Kan3 said: A question first: are you using the music you want to play in this way as a music track for the whole map or you're using it separately in a ZDoom thing in that room? After that: basically you just have to create an OPEN script in the script editor and use the function PlaySound(all of the parameters needed here); like the wiki shows. You then give a thing inside the sector you want a tid and write this as the first parameter of the PlaySound function. And no its not a music for the whole map its a "Sound" aka music that ONLY plays in that area that I showed in the picture all the way up, the same way the bar music plays in Duke Nukem 3D E1M2. 0 Quote Share this post Link to post
Kan3 Posted April 21, 2022 Seen the CustomAmbientSound Thing (that I never even know about its existance) I'm quite sure you don't need anything else to make it work actually. You need to modify your SNDINFO lump though. If you want to use CustomAmbientSound you need to first define an actual ambient sound like it specifies here. So, in your context, your SNDINFO should look like this: $ambient 14065 DISCOO continuous 1.0 (under your "DISCOO DISCOO" obviously, which is still necessary). Now you can use this sound/music with that thing (Specified with the index parameter "14065", where you can choose which existing thing should play a sound). Inside the builder now, place a CustomAmbientSoun, select the right index (that should be the one that you just created), the volume you want, the minimum fading distance in map units and the maximum heard distance in map units (you need to set a value for both to apply the changes, that you can see with the circles emitted by the thing in the editor), the distance multiplier is not really needed. Just for info purposes: Did you "include" zcommon.acs ? And in the first parameter you don't write the thing type, but the tid/tag that you set on the thing (in that case I can see that it has a tag of 29) and with an attenuation so high you will basically be able to hear the music only in that room and nowhere else. 0 Quote Share this post Link to post
boobzooka Posted April 21, 2022 Thanks man it worked, unfortunately it doesnt have low pass filter but this is fine by me. 1 Quote Share this post Link to post
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.