[Solved!] SFX Volume based on music volume

Discussion in 'Programming' started by TheStatPow, Nov 2, 2015.

  1. TheStatPow

    TheStatPow
    Expand Collapse

    Joined:
    Aug 8, 2013
    Messages:
    145
    As of right now im working on a in-game music player, it as been requested on the suggestion sub-forum so i thought i'd get on it.

    I managed to play music and attach it on a node. thing is, the engine volume surpass the music volume, and the music (which is 3D) counts as a sound effect and is tied to the Effect volume in the options, i'd like it to be tied to the music volumes in the options.

    How would i manage that code wise?

    Im using this as of right now to play music:

    local music = gameEngine:createSFXSource('art/music/aFewOldTunesVol2.wav', "AudioCloseLoop3D", "test", true)

    obj:attachSFXNode(music, 2)



    EDIT: Nevermind, found it. i feel really stupid, but here is the answer if somebody else encounter the same thing.

    Use "AudioMusic3D" instead :\

    So damn obvious x)
     
    #1 TheStatPow, Nov 2, 2015
    Last edited: Nov 2, 2015
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice