[Solved]Formation snipet

Status
Not open for further replies.

MooshraKun

Making Dreams Stand Up
Veteran
Joined
Jul 11, 2012
Messages
238
Reaction score
11
First Language
Lokota
I was wondering if someone could make a little snippet to where when the formation button is selected it please a sound effect file just something where I can input the file name and when the option is selected it plays it.
 
Last edited by a moderator:

Todd

Game Developer
Veteran
Joined
Mar 14, 2012
Messages
269
Reaction score
43
First Language
English
Primarily Uses
N/A
Like this?



Code:
#===============================================================================
#
# Formation Sound effect
# Author: Todd
# Date (07/24/2012)
# Version: (1.0.0) (VXA)
# Level: (Simple)
# Email: Support@beacongames.com
#
#===============================================================================
module TODDSEFORM

#The sound effect to use
SE = "Darkness7"

end
#==============================================================================
# ** Scene_Menu
#------------------------------------------------------------------------------
# This class performs the menu screen processing.
#==============================================================================

class Scene_Menu < Scene_MenuBase
#--------------------------------------------------------------------------
# * Formation [OK]
#--------------------------------------------------------------------------
alias todd_on_formation_ok_se on_formation_ok
def on_formation_ok
todd_on_formation_ok_se
Audio.se_play("Audio/SE/" + TODDSEFORM::SE, 100, 100)
end
end
 

MooshraKun

Making Dreams Stand Up
Veteran
Joined
Jul 11, 2012
Messages
238
Reaction score
11
First Language
Lokota
Not quite this plays a sound every time you select a character. I only want it to play a sound when the button Formation is hit.
 

Mr. Bubble

Makes stuff.
Member
Joined
Mar 1, 2012
Messages
853
Reaction score
163
Not quite this plays a sound every time you select a character. I only want it to play a sound when the button Formation is hit.

Code:
class Scene_Menu < Scene_MenuBase
  FORMATION_SE = "Attack2"
  alias command_formation_sound_effect command_formation
  def command_formation
    Audio.se_play("Audio/SE/" + FORMATION_SE, 80, 100)
    command_formation_sound_effect
  end
end
 

MooshraKun

Making Dreams Stand Up
Veteran
Joined
Jul 11, 2012
Messages
238
Reaction score
11
First Language
Lokota
Thanks Mr Bubble it works great.
 

Mr. Bubble

Makes stuff.
Member
Joined
Mar 1, 2012
Messages
853
Reaction score
163
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
 
Status
Not open for further replies.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,849
Messages
1,016,977
Members
137,563
Latest member
cexojow
Top