• a logic entitiy based sound system
    3 replies, posted
hi everyone,i'm trying to make a soundplayer for my map simaller to the one from mobenix, and if i butcher this thread's spelling its because i'm REALLY F*CKING TIRED ok, so i have 4 buttons; previous, next, play, and stop. i have a math counter to select the song, and a logic case to compare the math counter to ceratin numbers. now i need the math counter to output the name of the ambient_generic that plays the sound (the entity names are SounPlay 1-5) and the play/stop button to recieve these inputs of entity names, and use them in ab output: OnPressed <ambient_generic name here> soundplay and also for soundstop. anyone know how to do this
[QUOTE=wardino388;17163273]hi everyone,i'm trying to make a soundplayer for my map simaller to the one from mobenix, and if i butcher this thread's spelling its because i'm REALLY F*CKING TIRED ok, so i have 4 buttons; previous, next, play, and stop. i have a math counter to select the song, and a logic case to compare the math counter to ceratin numbers. now i need the math counter to output the name of the ambient_generic that plays the sound (the entity names are SounPlay 1-5) and the play/stop button to recieve these inputs of entity names, and use them in ab output: OnPressed <ambient_generic name here> soundplay and also for soundstop. anyone know how to do this[/QUOTE] I made a similar selector for a Portal map. Don't use math_counter at all. All you need are 15 logic_relays. name them radionext1, radioprev1, radioplay1, radionext2, radioprev2, radioplay2, radionext3, radioprev3, radioplay3, radionext4, radioprev4, radioplay4, radionext5, radioprev5, and radioplay5. They should all start disabled except for radionext1, radioprev1, and radioplay1. Assuming your ambient_generics are named music1, music2, music3, music4, and music5: radionext1: On Trigger - radionext1 - Disable On Trigger - radionext2 - Enable On Trigger - radioprev1 - Disable On Trigger - radioprev2 - Enable On Trigger - radioplay1 - Disable On Trigger - radioplay2 - Enable On Trigger - music1 - StopSound radioprev1: On Trigger - radionext1 - Disable On Trigger - radionext5 - Enable On Trigger - radioprev1 - Disable On Trigger - radioprev5 - Enable On Trigger - radioplay1 - Disable On Trigger - radioplay5 - Enable On Trigger - music1 - StopSound radioplay1: On Trigger - music1 - PlaySound The stop button should stop all of the music. The play button should fire all of the play relays. The next should fire all of the next relays. The prev should fire all of the prev relays. This is the way Valve tends to do it as well. (Decompile Portal's Chamber 17 and you'll see a prime example. GLaDOS talks about murdering your Companion Cube with the exact same setup.)
[QUOTE=darkspork;17172475]I made a similar selector for a Portal map. Don't use math_counter at all. All you need are 15 logic_relays. name them radionext1, radioprev1, radioplay1, radionext2, radioprev2, radioplay2, radionext3, radioprev3, radioplay3, radionext4, radioprev4, radioplay4, radionext5, radioprev5, and radioplay5. They should all start disabled except for radionext1, radioprev1, and radioplay1. Assuming your ambient_generics are named music1, music2, music3, music4, and music5: radionext1: On Trigger - radionext1 - Disable On Trigger - radionext2 - Enable On Trigger - radioprev1 - Disable On Trigger - radioprev2 - Enable On Trigger - radioplay1 - Disable On Trigger - radioplay2 - Enable On Trigger - music1 - StopSound radioprev1: On Trigger - radionext1 - Disable On Trigger - radionext5 - Enable On Trigger - radioprev1 - Disable On Trigger - radioprev5 - Enable On Trigger - radioplay1 - Disable On Trigger - radioplay5 - Enable On Trigger - music1 - StopSound radioplay1: On Trigger - music1 - PlaySound The stop button should stop all of the music. The play button should fire all of the play relays. The next should fire all of the next relays. The prev should fire all of the prev relays. This is the way Valve tends to do it as well. (Decompile Portal's Chamber 17 and you'll see a prime example. GLaDOS talks about murdering your Companion Cube with the exact same setup.)[/QUOTE] sadly i dont have portal, i beat it on XBOX and didnt bother to buy the game for PC
[QUOTE=wardino388;17385397]sadly i dont have portal, i beat it on XBOX and didnt bother to buy the game for PC[/QUOTE] make it custom sounds then, download portal: first slice and extract the sounds from the gcf
Sorry, you need to Log In to post a reply to this thread.