#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= # Blizz ABS Active Action Info # Version: 1.52 # Author : LiTTleDRAgo #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= module ZetsuDrago ACT_HUD_X = 200 ACT_HUD_Y = 400 ACT_FONT = 'Calibri' ACT_SIZE = 20 ACT_BOLD = true ACT_ITALIC = true ACT_SE = "EF_Pop10" ACT_SWITCH = 47 end #============================================================================== # Config End #============================================================================== class Game_Temp attr_accessor :act_hud ; attr_accessor :act_text_zoom attr_accessor :act_text; attr_accessor :act_start alias_method :drago_act_initialize, :initialize def initialize drago_act_initialize @act_hud, @act_text_zoom = [], [] @act_hud[1...13] = 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 @act_text_zoom[1], @act_text_zoom[2] = 1.00, 1.00 @act_text, @act_start = "", false end end class Game_System alias_method :drago25_init, :initialize def mpit() @mpit ||= [0, 0, 1, 1, 0, 0] end end class Interpreter alias_method :drago25_command126, :command_126 alias_method :drago25_command127, :command_127 alias_method :drago25_command128, :command_128 alias_method :drago25_command125, :command_125 def command_126; drago25_command126; $game_system.mpit[5] = 1; parsys; end def command_127; drago25_command127; $game_system.mpit[5] = 2; parsys; end def command_128; drago25_command128; $game_system.mpit[5] = 3; parsys; end def command_125; drago25_command125; $game_system.mpit[5] = 4 $game_system.mpit[4] = operate_value(@parameters[0], @parameters[1], @parameters[2]) end def parsys $game_system.mpit[3], @param, $ref = @parameters[0], @parameters, true $game_system.mpit[4] = operate_value (@param[1], @param[2], @param[3]) end end class Game_Map attr_reader :map_id def mpitnm $mpitnm = load_data("Data/Items.rxdata") $mpitnm[$game_system.mpit[3]].name; end; def mpwpnm $mpwpnm = load_data("Data/Weapons.rxdata") $mpwpnm[$game_system.mpit[3]].name; end; def mparnm $mparnm = load_data("Data/Armors.rxdata") $mparnm[$game_system.mpit[3]].name end end class Window_Base < Window SWITCH = ZetsuDrago::ACT_SWITCH def draw_mpitem(x,y) $game_system.mpit = [] if $game_system.mpit == nil dev, @gam, @map = "Got "+$game_system.mpit[4].to_s, $game_system, $game_map $game_temp.act_text = dev + " x " + @map.mpitnm.to_s if @gam.mpit[5] == 1 $game_temp.act_text = dev + " x " + @map.mpwpnm.to_s if @gam.mpit[5] == 2 $game_temp.act_text = dev + " x " + @map.mparnm.to_s if @gam.mpit[5] == 3 $game_temp.act_text = dev+" "+$data_system.words.gold if @gam.mpit[5] == 4 if @gam.mpit[5] != 0 && $game_switches[SWITCH] && $game_system.mpit[4] > 0 $game_temp.act_hud[13], $game_temp.act_start = 20, true Audio.se_play("Audio/SE/" + ZetsuDrago::ACT_SE , 70, 100) rescue nil end end end if $BlizzABS && BlizzABS::VERSION >= 2.7 class Map_Battler alias use_skill_activeinfo_earlier use_skill def use_skill(skill,*args) result = use_skill_activeinfo_earlier(skill,*args) draw_skl(skill.name) if result return result end alias use_item_activeinfo_earlier use_item def use_item(item,*args) result = use_item_activeinfo_earlier(item,*args) draw_item(item.name) if result return result end def draw_skl(value) if @battler.is_a?(Game_Actor) && $game_switches[ZetsuDrago::ACT_SWITCH] && @battler.id == $game_party.actors[0].id $game_temp.act_text = value $game_temp.act_hud[13], $game_temp.act_start = 20, true end end def draw_item(value) if @battler.is_a?(Game_Actor) && $game_switches[ZetsuDrago::ACT_SWITCH] && @battler.id == $game_party.actors[0].id $game_temp.act_text = "Use "+ value $game_temp.act_hud[13], $game_temp.act_start = 20, true end end end end class Act < Sprite ACT_HUD_X, ACT_HUD_Y = ZetsuDrago::ACT_HUD_X, ZetsuDrago::ACT_HUD_Y def initialize @viewport = Viewport.new(0, 0, 640, 480) @viewport.z = 99999 super(@viewport) @hud1, @hud2, @hud3, @text = Sprite.new, Sprite.new, Sprite.new, Sprite.new @hud1.bitmap = RPG::Cache.picture("AF_Lay1") rescue RPG::Cache.picture("") @hud2.bitmap = RPG::Cache.picture("AF_Lay2") rescue RPG::Cache.picture("") @hud3.bitmap = RPG::Cache.picture("AF_Lay3") rescue RPG::Cache.picture("") @text.bitmap = Bitmap.new(120,40); hudposition @hud1.z, @hud2.z, @hud3.z, @text.z = 9000, 9000, 9003, 9002 @text.bitmap.font.name = ZetsuDrago::ACT_FONT @text.bitmap.font.size = ZetsuDrago::ACT_SIZE @text.bitmap.font.bold = ZetsuDrago::ACT_BOLD @text.bitmap.font.italic = ZetsuDrago::ACT_ITALIC @text.bitmap.font.color.set(250, 250, 250, 220) end def dispose [@hud1, @hud2, @hud3, @text, @viewport].each {|s| s.dispose if s != nil} end def refresh @temp.act_start = false; @text.bitmap.clear @xhud[9], @xhud[10], @xhud[11], @xhud[12], @xhud[1], @xhud[2], @zoom[1], @xhud[7] = 100, 100, 100, 100, 100, -100, 1.50, 0 @text.bitmap.draw_text(0, 0, 120, 40, @temp.act_text.to_s,1) end def update hudposition @xhud[13] -= 1 if @xhud[13] > 0 if @xhud[13] > 0 @xhud[9] += 10 if @xhud[9] < 255; @xhud[10] += 10 if @xhud[9] < 255 @xhud[11] += 10 if @xhud[9] < 255; @xhud[12] += 10 if @xhud[9] < 255 @xhud[1] -= 10 if @xhud[1] > 0; @xhud[2] += 10 if @xhud[1] > 0 @xhud[1] = @xhud[2] = 0 if @xhud[1] < 0;@zoom[1] -= 0.1 if @zoom[1] > 1.00 @zoom[1] = 1.00 if @zoom[1] < 1.00; @zoom[2] = 1.00 if @zoom[1] < 1.00 @xhud[4] = 0 if @zoom[1] < 1.00 else @xhud[9] -= 10 if @xhud[9] > 0; @xhud[10] -= 10 if @xhud[9] > 0 @xhud[11] -= 10 if @xhud[9] > 0; @xhud[12] -= 10 if @xhud[9] > 0 @xhud[1] -= 10 if @xhud[1] < 100; @xhud[2] += 10 if @xhud[1] < 100 @xhud[1] = @xhud[2] = 100 if @xhud[1] > 100 end refresh if @temp.act_start == true end def hudposition @hud1.ox, @temp = -ACT_HUD_X + $game_temp.act_hud[1], $game_temp @hud1.oy, @xhud = -ACT_HUD_Y + @temp.act_hud[5], $game_temp.act_hud @hud2.ox, @zoom = -ACT_HUD_X - 50 + @xhud[2], $game_temp.act_text_zoom @hud2.oy = -ACT_HUD_Y - 20 + @xhud[6]; @hud3.ox = -ACT_HUD_X - 80 + @xhud[3] @hud3.oy = -ACT_HUD_Y + 20 + @xhud[7]; @text.ox = -ACT_HUD_X - 50 + @xhud[4] @text.oy = -ACT_HUD_Y + 5 + @xhud[8] @hud1.opacity, @hud2.opacity = @xhud[9], @xhud[10] @hud3.opacity, @text.opacity = @xhud[11], @xhud[12] @text.zoom_x, @text.zoom_y = @zoom[1], @zoom[2] end end class Mpitem < Window_Base def initialize super(0, 0, 250, 100) self.contents, self.opacity = Bitmap.new(width - 32, height - 32), 0 self.contents.clear; refresh end def refresh; draw_mpitem(10,0); @gam.mpit[5] = 0; end end class Scene_Map alias_method :drago_act_main, :main alias_method :drago25_update, :update def main @act, @mpit = Act.new, Mpitem.new @mpit.visible, @mpit.contents_opacity = true, $game_system.mpit[6] drago_act_main;[@act, @mpit].each {|s| s.dispose if s != nil} @mpit = @act = nil end def update drago25_update @act.update if @act != nil; @mpit.refresh if @mpit != nil @mpit.x, @mpit.y, $ref = 200, 480, false if $ref == true $game_system.mpit[1], $game_system.mpit[2]= @mpit.x, @mpit.y @mpit.contents_opacity, @mpit.visible= $game_system.mpit[6], true @mpit.y -= 8 if @mpit.y > 380; @mpit.y = 380 if @mpit.y >= 380 $game_system.mpit[6] -= 3 end end