| 12-16-2003, 07:25 PM | #1 |
hello there. this sounds like a noobish question, but how do i get rid of the background music and replace it with somethin else? cos its really annoyin me and i cant seem 2 get rid of the music. any help? |
| 12-16-2003, 08:30 PM | #2 |
Well, I assume you're talking about music that begins right at the start of playing your map, or soon afterwards? If so, you should be able to get rid of it/change it by doing the following: Find one of your triggers that has an event "Map Initialization." If you have none, make one and call it "Set Music" or some such thing. The trigger should look something like this: Code:
Events:
Map initialization
Conditions:
[NONE](--- NOTE: The 'wait' number action can be altered of course, or you can leave it out completely if you don't want to set music to play right at the start of the map. I.E. You want music to play later on at a given time or event.) (--- NOTE: The 'Play music' action can be altered or removed, depending on what you want to play at map start, if anything. You can also change it to a 'Play music theme' action as well for more variety, or use a custom instead.) Code:
Actions:
Sound - Stop music immediately
Sound - Clear the music list
Wait 1.00 seconds
Sound - Play musicThat should fix it, or if nothing else, allow you to remove the initial music until a time when you want to play it. Hope that helps. -GabeStah- |
| 12-16-2003, 08:44 PM | #3 |
thx man it helped i want 2 play a randomly chosen music out of 2 or 3. how do u do that? |
| 12-16-2003, 10:03 PM | #4 |
Hmm, a bit more complex, but this should work, though it gets messier the more possibilities you add. Unfortunately, unlike regular 'Sounds,' there isn't a 'Music' variable to which you can assign various tracks, though the lists are obviously designed for that, I haven't figured out how to properly edit them or create one. Anyway, here you go. Let me know if this doesn't work. Code:
Events:
Map initialization
Conditions:
[NONE]
Actions:
Sound - Stop music Immediately
Sound - Clear music list
Wait - 1.00 seconds
Set var_intMusicRandomizer = (Random integer number between 1 and 3)
If (var_intMusicRandomizer Equal to 1) then do (Sound - Play BloodElfTheme <gen> ) else do (Do nothing)
If (var_intMusicRandomizer Equal to 2) then do (Sound - Play Doom <gen> ) else do (Do nothing)
If (var_intMusicRandomizer Equal to 3) then do (Sound - Play HumanDefeat <gen> ) else do (Do nothing)As I said, there might be a more efficient way of doing this if anyone knows how to create music lists, so you can essentially use a Sound Variable array to specify the exact music track rather than naming them seperately (once you can do that, you would easily be able to create a loop that could have any number of random tracks in it to pick from and not have to have a line of code for each possible track.) Hope that helps, -GabeStah- |
| 12-16-2003, 10:27 PM | #5 |
There is an easier way to do it. First of, lets say Player 1 is Human. You find the music, go to the sound editor, and replace Human 1, 2, 3, and X with your music. If you have too few musics of your own, replace the last few with this, Nothing.wav, from CoTN. NOTE: Once your replace a sound, you can't replace it back. You need to start over. -KillR |
| 12-17-2003, 06:54 PM | #6 |
ok that hels, but i have problem (yet another :D ). i dont know wat the variable is, since i never use them. any help? |
| 02-06-2004, 05:02 PM | #7 |
hey have waited for about 6 months with no reply! |
| 02-06-2004, 05:22 PM | #8 |
No one has answered because you asked such a vague question. You could of searched for topics on variables, btw. In a nutshell, a variable might hold a number, for instance. You could add to the number, and the number 'held' by the variable would also go up. OK, im probably confusing you so... Here. http://www.wc3campaigns.com/forums/s...ight=variables |
