Jump to content
Rpg²S Forum

Rumore Passi


rizzuccio
 Share

Recommended Posts

Salve, a quanto pare nel forum manca uno script funzionante per i rumori dei passi...

 

Ebbene ne ho appena trovato uno (testato e funzionante) sul forum : rpgmaker.net

Creato da : game_guy (penso XD)

 

Come al solito basta incollare sopra main questo script :

 

 

#===============================================================================# Terrain Step Sound# Version 1.1# Author game_guy#-------------------------------------------------------------------------------# Intro:# Create nice aesthetics with terrain noise. As you walk across grass or sand,# let it play a beautiful noise to add to the atmosphere and realism of the# game.## Features:# Specific Sound for Each Terrain# Specific Sounds for Each Tileset# Specify Volume and Pitch## Instructions:# Setup the config below, its pretty self explanatory, more instructions# with config.## Credits:# game_guy ~ For creating it# Tuggernuts ~ For requesting it a long time ago# Sase ~ For also requeseting it#===============================================================================module TSS  # In Frames Recommended 5-10  Wait = 5  # Ignore the next 2 lines  Terrains = []  Tilesets = []  #===========================================================================  # Enter in sounds for each terrain tag  # Goes from 0-8. Set as nil to disable that terrain or delete the line.  #===========================================================================  Terrains[0] = '001-System01'  Terrains[1] = ''  Terrains[2] = ''  Terrains[3] = ''  Terrains[4] = ''  Terrains[5] = ''  Terrains[6] = ''  #===========================================================================  # If you would like to specifiy a volume and pitch, simply set the  # terrain as an array.  # Terrains[7] = ["sound", volume, pitch]  # Just set it as a string if you would like the volume to be at 100 and  # pitch at 0.  # This also applies for tilesets below.  #===========================================================================  Terrains[7] = ["sound", 80, 10]  #===========================================================================  # With tilesets, you can set specific sounds for each tileset so you don't  # have the same sounds. Add a new line and put  # Tilesets[tileset id] = []  # Then for each terrain put  # Tilesets[tileset id][terrain id] = "sound file"  # If a sound doesn't exist for a tileset, it will play a default sound,  # if a default doesn't exist, no sound at all.  #===========================================================================  Tilesets[1] = []  Tilesets[1][0] = "001-System01"  Tilesets[1][1] = ["001-System01", 75, 50]endclass Game_Map  def terrain_sound    if TSS::Tilesets[@map.tileset_id] != nil      return TSS::Tilesets[@map.tileset_id][$game_player.terrain_tag]    else      return TSS::Terrains[$game_player.terrain_tag]    end    return nil  endendclass Scene_Map  alias gg_init_terrain_sounds_lat initialize  def initialize    @tsswait = TSS::Wait    gg_init_terrain_sounds_lat  end  alias gg_update_terrain_sounds_lat update  def update    if $game_player.moving?      @tsswait -= 1      terrain = $game_map.terrain_sound      if terrain != nil        if @tsswait == 0          vol = terrain.is_a?(Array) ? terrain[1] : 100          pit = terrain.is_a?(Array) ? terrain[2] : 0          son = terrain.is_a?(Array) ? terrain[0] : terrain          Audio.se_play('Audio/SE/' + son, vol, pit)          @tsswait = TSS::Wait        end      end    end    gg_update_terrain_sounds_lat  endend

 

 

 

Per inserire un suono SE bisogna inserire il nome del suono dove cè la lista dei : terrains (il nome del suono andra' scritto fra le apostrofo).

Inoltre mi è capitato che su un nuovo progetto questo non basta, ma modificando la parola : 001-System01

dove cè scritto Tileset, inserendo il nome del vostro suono, torna a funzionare tutto.

 

Spero possa essere utile =)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...