#--------------------------------------------------------------------------
# 射击
#--------------------------------------------------------------------------
alias mog_actname_shoot shoot
def shoot(action_id)
mog_actname_shoot(action_id)
if action_id == nil or action_id == 0
return
end
item_id = XAS::ITEM_COST[action_id]
if self.battler.is_a?(Game_Actor) and
$data_skills[action_id].element_set.include?($data_system.elements.index("Name_ON"))
if item_id != nil and $game_party.item_number(item_id) == 0
$game_system.se_play($data_system.buzzer_se)
return
end
skill_sp_cost = $data_skills[action_id].sp_cost
if self.battler.sp >= skill_sp_cost and
$game_temp.cast_time == 0
$game_temp.if_text = $data_skills[action_id].name
$game_temp.if_text_time = 20 + Database_Bullet::DURATIONS[action_id]
$game_temp.if_start = true
end
end
end
end
#==============================================================================
# IFA
#==============================================================================
class Ifa < Sprite
include MOG
#--------------------------------------------------------------------------
# 滑动刷新
#--------------------------------------------------------------------------
def slide_update
$game_temp.if_text_time -= 1 if $game_temp.if_text_time > 0
if $game_temp.if_text_time > 0
if $game_temp.if_hud1_opa < 255
$game_temp.if_hud1_opa += 10
$game_temp.if_hud2_opa += 10
$game_temp.if_hud3_opa += 10
$game_temp.if_text_opa += 10
end
if $game_temp.if_hud1_x > 0
$game_temp.if_hud1_x -= 10
$game_temp.if_hud2_x += 10
elsif $game_temp.if_hud1_x < 0
$game_temp.if_hud1_x = 0
$game_temp.if_hud2_x = 0
end
if $game_temp.if_text_zoom_x > 1.00
$game_temp.if_text_zoom_x -= 0.1
elsif $game_temp.if_text_zoom_x < 1.00
$game_temp.if_text_zoom_x = 1.00
$game_temp.if_text_zoom_y = 1.00
$game_temp.if_text_x = 0
end
else
if $game_temp.if_hud1_opa > 0
$game_temp.if_hud1_opa -= 10
$game_temp.if_hud2_opa -= 10
$game_temp.if_hud3_opa -= 10
$game_temp.if_text_opa -= 10
end
if $game_temp.if_hud1_x < 100
$game_temp.if_hud1_x -= 10
$game_temp.if_hud2_x += 10
elsif $game_temp.if_hud1_x > 100
$game_temp.if_hud1_x = 100
$game_temp.if_hud2_x = 100
end
end
end
#--------------------------------------------------------------------------
# 刷新
#--------------------------------------------------------------------------
def update
hud_pos_update
slide_update
if $game_temp.if_start == true
refresh
end
end
end
#==============================================================================
# Scene_Map
#==============================================================================
class Scene_Map
#--------------------------------------------------------------------------
# Main
#--------------------------------------------------------------------------
alias mog_ifa_main main
def main
@ifa = Ifa.new
mog_ifa_main
@ifa.dispose
@ifa = nil
end
#--------------------------------------------------------------------------
# 刷新
#--------------------------------------------------------------------------
alias mog_ifa_update update
def update
mog_ifa_update
@ifa.update
end
end