Please or Register to create posts and topics.

How to create the musical effect seen in sp_a2_triple_laser?

Hi! So, I was wondering, you know the maps I described in the title? Well, they have a system where, instead of laser one playing sound one, laser two playing sound two and so on, the first laser activated, no matter which one, plays sound one, the second, sound two, and so on. How exactly would one go about achieving this? I tried decompiling the map, but the sounds don't even receive any inputs. If logic branches could be disabled, this would be a piece of cake, but they can't,nso it's, um, not. Any suggestions? Thanks!

Image
ImageImageImageImage

This is controlled by a vscript.

Really? That's annoying, and just as I was about to test my hawkish method using math counters... Does it work in custom maps? Andnhow would one go about settingmit up - you are the scripting god, after all. ;)

Image
ImageImageImageImage

Couldn't this easily be achieved with several math_counters?

1 would have a max of 1, one could have a max of 2, and the last could have a max of 3.

Portal 1.5 http://www.moddb.com/mods/portal-15

That's what I tried, but they also have to originate from each laser catcher by using SourceEntityName. Anyway, as for the script thing, is it as simple as setting the Entity Scripts value for each catcher to musical_laser_catcher.nut?

EDIT: It is. Thanks for the help!

Image
ImageImageImageImage

I didn't know about the entity scripts. Lol. But a way I thought of doing it is, because the three tracks are in the RAW folder of the sound browser, you could set up three ambient generics that start playing on the map spawn, but have their volumes set to 0. It would require a lot of different branches, etc. but you could eventually get an output where depending on how many lasers are enabled, the volumes for the corresponding ambient_generics would be set to >0

My Maps:
[spoiler][SP] Alternate[/spoiler]