(Sounds) Jukebox!

morno

Active Member
Reaction score
2
hi i need a ''Jukebox'' for my game nothing whit text in it just like 20kb-50kb and i whant it not loop the same sound all over and over again..

And i whant when the game starts it will select randomly so you don't get too bored and after it selected like Nr. 2 it will go to the next nr.3 i will have like 6-10, 20-50kb.. so that is my prob..

can anyone please help me?
 

Slapshot136

Divide et impera
Reaction score
471
import like 50-60 1 second sounds, at the start set a var with an array, and then like every 1 second of the game play a random 1 of those.. something like this?
 

morno

Active Member
Reaction score
2
i have found a good sound drippin water.. and i my trigger to play it is
Code:
Music Box
    Events
        Unit - A unit enters Water <gen>
    Conditions
    Actions
        Sound - Play watercave2 <gen>
        Sound - Set music volume to 100.00%

but i whant it to loop..
 

Psiblade94122

In need of sleep
Reaction score
138
hmm how bout this

Trigger 1
Code:
Music Box
    Events
        Unit - A unit enters Water <gen>
    Conditions
    Actions
        Sound - Play watercave2 <gen>
        Sound - Set music volume to 100.00%
        Count Down Timer - start (Music timer [ player number of owner of entering unit] as a one-shot timer that will last <lengh of song>

Trigger 2 <make the next trigger for every player> <*** means i have a comment for it later>
Code:
P1 Music Timer
    Events
        Music timer [1] expires
    Conditions
         integer - number of units owned by player red 1 in Water <gen> is equal to or greater then one ***
    Actions
        Sound - Play watercave2 <gen>
        Sound - Set music volume to 100.00%
        Count Down Timer - start (Music timer [1] as a one-shot timer that will last <lengh of song>

*** as always you can add extra conditions to that, to make it so its only for heros and spawned units wont trigger it

Code:
Music Box End
    Events
        Unit - A unit leaves Water <gen>
    Conditions
    Actions
        Sound - stop all music
        Count Down Timer - start (Music timer [ player number of owner of entering unit] as a one-shot timer that will last .01 seconds

the last trigger will get rid of the sound and will stop trigger 2 from happening (if the unit leaves, then it will not match the condition and the trigger wont fire)

i do not have wc3 to test this atm, but i will once i get my comp fixed
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top