Home:
  - News
  - Archives
  - Site Info
  - Mirage

Game Play:
  - Tips
  - Tricks
  - Moves
  - Cheats
  - Fun

Game Tech:
  - Playing
  - Oni Works
  - AI Dev

Dev Shed:
  - Script Lib
  - Sepics
  - Tool Kit
  - Downloads

Community:
  - Board
  - Links
  - Contests

Directory: Technical >> Script Lib >> Basics >> Audio.

Music:

One could identify music since music sounds since they begin with mus. You can only play music which is registered on the level. You can find this music at the end of the corresponding *.dat file. Make sure that you end each piece of music somewhere. To begin, a piece of music (it is looped) use the following line: (volume=0.0 mute to 1.0 loudest)

   sound_music_start [music] [volume]

To change the volume of a certain music piece (you may play two at once), type:

   sound_music_volume [music] [volume] [time]

Time is the time in seconds allowed to make a transition between the two volumes. Leave time blank if you do not want a transition. To stop a piece of music, use the following function:

   sound_music_stop [music]

Dialogs:

Some sounds could be used as dialogs or ambients; however, you should play the sound in the original format due to consistency and compatibility problems. You cannot play the same sound in dialog, impulse or ambient use. To play a dialog,

   sound_dialog_play [dialog]

To play a block of sounds you would need to use:

   sound_dialog_play_block [block]

Impulses:

To play an impulse sound (like c04_14_02konoko):

   sound_impulse_play [impulse]

Ambients:

Not all sounds are the same. For example the alarm_loop is looped unless it is stopped while others don't have to. Ambients are generally unlooped.

   sound_ambient_start [ambient]

To force stop an ambient, you have to use the line:

   sound_ambient_stop [ambient]


In the same way, you can change the volume of an ambient:

   sound_ambient_volume [ambient] [volume] [time]





© 2001-2004 by Oni Master. All rights reserved.
We are not affiliated with Bungie Studios nor Rockstar Games.