Spoiler
#_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
#_/ ◆ Battle Screen Effects - MRA_BattleScreenEffects ◆ VX ◆
#_/ ◇ Last Update: 2008/09/27 ◇
#_/ ◆ Created by Mr. Anonymous ◆
#_/ ◆ Creator's Blog: ◆
#_/ ◆ http://mraprojects.wordpress.com ◆
#_/----------------------------------------------------------------------------
#_/ This script enables weather and screen tone to carry over from the map
#_/ screen into battle.
#_/============================================================================
#_/ Aliased Methods: Spriteset_Battle's initialize, dispose, update,
#_/ update_viewports
#_/============================================================================
#_/ Install: Insert above main.
#_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
#=============================================================================#
# ★ Customization ★ #
#=============================================================================#
module MRA
module BattleScreenEffects
# ★ Weather Switch ID ★
# This allows you to designate a switch that enables or disables the
# continuation of weather from the map into battle.
WEATHER_SWITCH_ID = 1
# ★ Screen Tone Switch ID ★
# This allows you to designate a switch that enables or disables the
# continuation of screen tone from the map into battle.
TONE_SWITCH_ID = 2
end
end
#=============================================================================#
# ★ End Customization ★ #
#=============================================================================#
#==============================================================================
# ** Spriteset_Battle
#------------------------------------------------------------------------------
# This class brings together battle screen sprites. It's used within the
# Scene_Battle class.
#==============================================================================
class Spriteset_Battle
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
alias initialize_mra_battle_screen_effects initialize
def initialize
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
create_weather
end
initialize_mra_battle_screen_effects
end
#--------------------------------------------------------------------------
# * Dispose
#--------------------------------------------------------------------------
alias dispose_mra_battle_screen_effects dispose
def dispose
dispose_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
dispose_weather
end
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias update_mra_battle_screen_effects update
def update
update_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
update_weather
end
end
#--------------------------------------------------------------------------
# * Update Viewport
#--------------------------------------------------------------------------
alias update_viewports_mra_battle_screen_effects update_viewports
def update_viewports
update_viewports_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::TONE_SWITCH_ID]
@viewport1.tone = $game_map.screen.tone
else
@viewport1.tone = $game_troop.screen.tone
end
end
#--------------------------------------------------------------------------
# * Create Weather
#--------------------------------------------------------------------------
def create_weather
@weather = Spriteset_Weather.new(@viewport2)
end
#--------------------------------------------------------------------------
# * Dispose of Weather
#--------------------------------------------------------------------------
def dispose_weather
@weather.dispose
end
#--------------------------------------------------------------------------
# * Update Weather
#--------------------------------------------------------------------------
def update_weather
@weather.type = $game_map.screen.weather_type
@weather.max = $game_map.screen.weather_max
@weather.ox = $game_map.display_x / 8
@weather.oy = $game_map.display_y / 8
@weather.update
end
end
#_/ ◆ Battle Screen Effects - MRA_BattleScreenEffects ◆ VX ◆
#_/ ◇ Last Update: 2008/09/27 ◇
#_/ ◆ Created by Mr. Anonymous ◆
#_/ ◆ Creator's Blog: ◆
#_/ ◆ http://mraprojects.wordpress.com ◆
#_/----------------------------------------------------------------------------
#_/ This script enables weather and screen tone to carry over from the map
#_/ screen into battle.
#_/============================================================================
#_/ Aliased Methods: Spriteset_Battle's initialize, dispose, update,
#_/ update_viewports
#_/============================================================================
#_/ Install: Insert above main.
#_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
#=============================================================================#
# ★ Customization ★ #
#=============================================================================#
module MRA
module BattleScreenEffects
# ★ Weather Switch ID ★
# This allows you to designate a switch that enables or disables the
# continuation of weather from the map into battle.
WEATHER_SWITCH_ID = 1
# ★ Screen Tone Switch ID ★
# This allows you to designate a switch that enables or disables the
# continuation of screen tone from the map into battle.
TONE_SWITCH_ID = 2
end
end
#=============================================================================#
# ★ End Customization ★ #
#=============================================================================#
#==============================================================================
# ** Spriteset_Battle
#------------------------------------------------------------------------------
# This class brings together battle screen sprites. It's used within the
# Scene_Battle class.
#==============================================================================
class Spriteset_Battle
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
alias initialize_mra_battle_screen_effects initialize
def initialize
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
create_weather
end
initialize_mra_battle_screen_effects
end
#--------------------------------------------------------------------------
# * Dispose
#--------------------------------------------------------------------------
alias dispose_mra_battle_screen_effects dispose
def dispose
dispose_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
dispose_weather
end
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias update_mra_battle_screen_effects update
def update
update_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::WEATHER_SWITCH_ID]
update_weather
end
end
#--------------------------------------------------------------------------
# * Update Viewport
#--------------------------------------------------------------------------
alias update_viewports_mra_battle_screen_effects update_viewports
def update_viewports
update_viewports_mra_battle_screen_effects
if $game_switches[MRA::BattleScreenEffects::TONE_SWITCH_ID]
@viewport1.tone = $game_map.screen.tone
else
@viewport1.tone = $game_troop.screen.tone
end
end
#--------------------------------------------------------------------------
# * Create Weather
#--------------------------------------------------------------------------
def create_weather
@weather = Spriteset_Weather.new(@viewport2)
end
#--------------------------------------------------------------------------
# * Dispose of Weather
#--------------------------------------------------------------------------
def dispose_weather
@weather.dispose
end
#--------------------------------------------------------------------------
# * Update Weather
#--------------------------------------------------------------------------
def update_weather
@weather.type = $game_map.screen.weather_type
@weather.max = $game_map.screen.weather_max
@weather.ox = $game_map.display_x / 8
@weather.oy = $game_map.display_y / 8
@weather.update
end
end
nn so come fare aiuto