Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Need help with RMVX sound script please.

Hiyas all,

Is there a way to change original RMVX battle start SE to something else ?
and is there a way to raise/lower the SE volume and pitch via scripting ?

For example this :-

  # Battle Start
  def self.play_battle_start
    $data_system.sounds[7].play
  end

Thank you in advance.
 
$data_system.sounds is an array with 20 RPG::SE objects as elements. So you only have to using another RPG::SE object instead of $data_system.sounds[blah].

Code:
# some comment lines
module Sound
  # filename, volume and pitch can be replaced (see RPG::AudioFile in the help file)
  BATTLE_START = RPG::SE.new(filename, volume, pitch)  # creates a new RPG::SE object
  # e.g.: BATTLE_START = RPG::SE.new('Cry', 50, 100)
  # Cry is the SE filename it will be played with the half of max. volume and default pitch

  # Cursor
  # ...
  # Battle Start
  def self.play_battle_start
    BATTLE_START.play()
  end
  # ...
end
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top