User Tag List

Results 1 to 2 of 2

Thread: Sound Volume from Instanced Source Objects?

  1. #1
    No Products Registered

    Join Date
    Jul 2007
    Location
    Iceland
    Posts
    13
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Sound Volume from Instanced Source Objects?

    Hi all,

    I'm dealing with an interesting dilemma in my game project. What I want to do is adjust the volume of a sound according to the distance from the player to the source. The trick is that the source is a duplicated (instanced) object.

    What I have so far: The object that's closest to the player is flagged and calculates the distance to the player and has the preferred volume as an Alterable value.

    What's the problem?: Assigning the volume data to the "Set Sample Volume" event using the correct source object. At the moment it's picking a source object at random and assigning the alterable value info from that as the sample volume.

    Any help on this is greatly appreciated.
    Thanks.


  2. #2
    No Products Registered

    Join Date
    Jul 2006
    Posts
    492
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Sound Volume from Instanced Source Objects?

    So your trying to make a positional audio system in MMF2. Until MMF2's sound system is upgraded somewhat, this is very awkward and probably not worth it.

    For example, there is no way to get the number of the last sound channel played on. So right off the bat you are going to have to design a sample/channel distribution which will be fairly complicated and also require a fair bit of looping, which could cause slowdown in your game.

    Every time you play a sound, you'd need to put a piece of code next to it that set the volume/panning of the appropriate channel. If you wanted looping sounds that move with the source then you'd need to find a way of constantly updating the volume/pan of the channel.

    There used to be an extension for MMF1.5 called DirectSound 2 that could do all this and more, but the developer mysteriously lost the source code and so MMF2 has suffered as a result. I've heard a few rumours that someone is working on a new positional sound object, so I'd just hang on until then.

Similar Threads

  1. Master Volume, Channel Volume, Sound Volume
    By BHGames in forum iOS Export Module Version 2.0
    Replies: 14
    Last Post: 18th December 2010, 12:11 PM
  2. Instanced active objects
    By JohnC in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 2nd November 2010, 08:36 PM
  3. Measuring the sound volume
    By Mantis in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 11th August 2007, 05:17 PM
  4. Sound Volume
    By Shmoo in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 14th February 2007, 03:57 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •