mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
Removed more RMVX compatibility
This commit is contained in:
@@ -53,7 +53,7 @@ def pbBGMPlay(param,volume=nil,pitch=nil)
|
||||
return if !param
|
||||
param=pbResolveAudioFile(param,volume,pitch)
|
||||
if param.name && param.name!=""
|
||||
if $game_system && $game_system.respond_to?("bgm_play")
|
||||
if $game_system
|
||||
$game_system.bgm_play(param)
|
||||
return
|
||||
elsif (RPG.const_defined?(:BGM) rescue false)
|
||||
@@ -72,10 +72,10 @@ def pbBGMFade(x=0.0); pbBGMStop(x); end
|
||||
|
||||
# Fades out or stops BGM playback. 'x' is the time in seconds to fade out.
|
||||
def pbBGMStop(timeInSeconds=0.0)
|
||||
if $game_system && timeInSeconds>0.0 && $game_system.respond_to?("bgm_fade")
|
||||
if $game_system && timeInSeconds > 0.0
|
||||
$game_system.bgm_fade(timeInSeconds)
|
||||
return
|
||||
elsif $game_system && $game_system.respond_to?("bgm_stop")
|
||||
elsif $game_system
|
||||
$game_system.bgm_stop
|
||||
return
|
||||
elsif (RPG.const_defined?(:BGM) rescue false)
|
||||
@@ -103,7 +103,7 @@ def pbMEPlay(param,volume=nil,pitch=nil)
|
||||
return if !param
|
||||
param=pbResolveAudioFile(param,volume,pitch)
|
||||
if param.name && param.name!=""
|
||||
if $game_system && $game_system.respond_to?("me_play")
|
||||
if $game_system
|
||||
$game_system.me_play(param)
|
||||
return
|
||||
elsif (RPG.const_defined?(:ME) rescue false)
|
||||
@@ -153,7 +153,7 @@ def pbBGSPlay(param,volume=nil,pitch=nil)
|
||||
return if !param
|
||||
param=pbResolveAudioFile(param,volume,pitch)
|
||||
if param.name && param.name!=""
|
||||
if $game_system && $game_system.respond_to?("bgs_play")
|
||||
if $game_system
|
||||
$game_system.bgs_play(param)
|
||||
return
|
||||
elsif (RPG.const_defined?(:BGS) rescue false)
|
||||
@@ -172,10 +172,10 @@ def pbBGSFade(x=0.0); pbBGSStop(x); end
|
||||
|
||||
# Fades out or stops BGS playback. 'x' is the time in seconds to fade out.
|
||||
def pbBGSStop(timeInSeconds=0.0)
|
||||
if $game_system && timeInSeconds>0.0 && $game_system.respond_to?("bgs_fade")
|
||||
if $game_system && timeInSeconds > 0.0
|
||||
$game_system.bgs_fade(timeInSeconds)
|
||||
return
|
||||
elsif $game_system && $game_system.respond_to?("bgs_play")
|
||||
elsif $game_system
|
||||
$game_system.bgs_play(nil)
|
||||
return
|
||||
elsif (RPG.const_defined?(:BGS) rescue false)
|
||||
@@ -203,7 +203,7 @@ def pbSEPlay(param,volume=nil,pitch=nil)
|
||||
return if !param
|
||||
param = pbResolveAudioFile(param,volume,pitch)
|
||||
if param.name && param.name!=""
|
||||
if $game_system && $game_system.respond_to?("se_play")
|
||||
if $game_system
|
||||
$game_system.se_play(param)
|
||||
return
|
||||
end
|
||||
@@ -236,12 +236,8 @@ end
|
||||
|
||||
# Plays a sound effect that plays when the player moves the cursor.
|
||||
def pbPlayCursorSE
|
||||
if $data_system && $data_system.respond_to?("cursor_se") &&
|
||||
$data_system.cursor_se && $data_system.cursor_se.name!=""
|
||||
if !nil_or_empty?($data_system&.cursor_se&.name)
|
||||
pbSEPlay($data_system.cursor_se)
|
||||
elsif $data_system && $data_system.respond_to?("sounds") &&
|
||||
$data_system.sounds && $data_system.sounds[0] && $data_system.sounds[0].name!=""
|
||||
pbSEPlay($data_system.sounds[0])
|
||||
elsif FileTest.audio_exist?("Audio/SE/GUI sel cursor")
|
||||
pbSEPlay("GUI sel cursor",80)
|
||||
end
|
||||
@@ -249,12 +245,8 @@ end
|
||||
|
||||
# Plays a sound effect that plays when a decision is confirmed or a choice is made.
|
||||
def pbPlayDecisionSE
|
||||
if $data_system && $data_system.respond_to?("decision_se") &&
|
||||
$data_system.decision_se && $data_system.decision_se.name!=""
|
||||
if !nil_or_empty?($data_system&.decision_se&.name)
|
||||
pbSEPlay($data_system.decision_se)
|
||||
elsif $data_system && $data_system.respond_to?("sounds") &&
|
||||
$data_system.sounds && $data_system.sounds[1] && $data_system.sounds[1].name!=""
|
||||
pbSEPlay($data_system.sounds[1])
|
||||
elsif FileTest.audio_exist?("Audio/SE/GUI sel decision")
|
||||
pbSEPlay("GUI sel decision",80)
|
||||
end
|
||||
@@ -262,12 +254,8 @@ end
|
||||
|
||||
# Plays a sound effect that plays when a choice is canceled.
|
||||
def pbPlayCancelSE
|
||||
if $data_system && $data_system.respond_to?("cancel_se") &&
|
||||
$data_system.cancel_se && $data_system.cancel_se.name!=""
|
||||
if !nil_or_empty?($data_system&.cancel_se&.name)
|
||||
pbSEPlay($data_system.cancel_se)
|
||||
elsif $data_system && $data_system.respond_to?("sounds") &&
|
||||
$data_system.sounds && $data_system.sounds[2] && $data_system.sounds[2].name!=""
|
||||
pbSEPlay($data_system.sounds[2])
|
||||
elsif FileTest.audio_exist?("Audio/SE/GUI sel cancel")
|
||||
pbSEPlay("GUI sel cancel",80)
|
||||
end
|
||||
@@ -275,12 +263,8 @@ end
|
||||
|
||||
# Plays a buzzer sound effect.
|
||||
def pbPlayBuzzerSE
|
||||
if $data_system && $data_system.respond_to?("buzzer_se") &&
|
||||
$data_system.buzzer_se && $data_system.buzzer_se.name!=""
|
||||
if !nil_or_empty?($data_system&.buzzer_se&.name)
|
||||
pbSEPlay($data_system.buzzer_se)
|
||||
elsif $data_system && $data_system.respond_to?("sounds") &&
|
||||
$data_system.sounds && $data_system.sounds[3] && $data_system.sounds[3].name!=""
|
||||
pbSEPlay($data_system.sounds[3])
|
||||
elsif FileTest.audio_exist?("Audio/SE/GUI sel buzzer")
|
||||
pbSEPlay("GUI sel buzzer",80)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user