SHADERS Posted December 15, 2009 Author Share Posted December 15, 2009 ```#==============================================================================# ¦ New_Battle#------------------------------------------------------------------------------# Compiled By : MakirouAru#==============================================================================# ÂÂ¥£ÂÂÂ¥ XRXS_BP 3\. Ÿâ€â€Ã‹Å“ŽžHP‰ñ•œ ver.1.01 ÂÂ¥£ÂÂÂ¥# by fukuyama, ÂÂ÷‰ë ÂÂÓy# Battle_End_Recovery## ÂÂÓ¬Œã‚̉ñ•œÂˆâ€â€Ã‚ƒ‚ƒWƒ…ÂÂ[ƒ‹## Request: stay# Script: fukuyama# Test: Æ’mÆ’RÆ’mŽq# # URL: http://www4.big.or.jp/~fukuyama/rgss/Battle_End_Recovery.txt#module Battle_End_Recovery module Scene_Battle_Module # ‰ñ•œâ€â€Ã‚¦â€¢ÃÂÂÂâ€Â‚ÌID @@recovery_rate_variable_id = nil # ‰ñ•œâ€â€Ã‚¦â€šÃŒÅ½Ã¦â€œÂ¾ def battle_end_recovery_rate if @@recovery_rate_variable_id.nil? @@recovery_rate_variable_id = $data_system.variables.index 'ÂÂÓ¬Œã‚̉ñ•œâ€â€Ã‚¦' if @@recovery_rate_variable_id.nil? @@recovery_rate_variable_id = false end end return 0 unless @@recovery_rate_variable_id return $game_variables[@@recovery_rate_variable_id] end # ÂÂÓ¬Œã‚̉ñ•œÂˆâ€â€Ã‚ def battle_end_recovery # ‰ñ•œâ€â€Ã‚¦ recovery_rate = battle_end_recovery_rate # ‰ñ•œâ€â€Ã‚¦â€¢ÃÂÂÂâ€Â‚ª‚OˆÈŠO‚©‚ƒAÆ’NÆ’^ÂÂ[‚ªÂ¶‘¶‚µ‚Ä‚¢‚éÂÂê‡ÂÂAÂÂÓ¬Œã‚̉ñ•œÂˆâ€â€Ã‚‚ðÂÂs‚¤ if recovery_rate != 0 and not actor.dead? # Æ’pÂÂ[Æ’eÆ’B‚̃AÆ’NÆ’^ÂÂ[–ˆ‚Ƀ‹ÂÂ[Æ’v $game_party.actors.each do |actor| # ‰ñ•œâ€â€ÃƒÅ Å’vŽZ recovery_hp = (actor.maxhp / 100.0 * recovery_rate).truncate recovery_sp = (actor.maxsp / 100.0 * recovery_rate).truncate # ŽÀÂÂۂɉñ•œ actor.hp += recovery_hp actor.sp += recovery_sp # Æ’AÆ’jÆ’ÂÂÂÂ[Æ’Vƒ‡ƒ“ÂÂÃÂ’è actor.damage = - recovery_hp actor.damage_pop = true end # Æ’XÆ’eÂÂ[Æ’^Æ’XÆ’EÆ’Bƒ“ƒhÆ’E‚ðÂÂXÂÂV @status_window.refresh end end end # module Scene_Battle_Moduleend # module Battle_End_Recovery#------------------------------# ÂÂÓ¬ƒVÂÂ[ƒ“‚ÌÂÂÄ’è‹`#------------------------------class Scene_Battle # Scene_Battleâ€â€pƒ‚ƒWƒ…ÂÂ[ƒ‹‚ðƒCƒ“ƒNƒ‹ÂÂ[Æ’h include Battle_End_Recovery::Scene_Battle_Module # Œ³‚̃tÆ’FÂÂ[Æ’Y‚TÃ…Â JŽn‚É•Ê–¼‚ð‚‚¯‚é alias battle_end_recovery_original_start_phase5 start_phase5 # Æ’tÆ’FÂÂ[Æ’Y‚TÃ…Â JŽn‚ðÂÂÄ’è‹` def start_phase5 # ÂÂÓ¬Œã‚̉ñ•œÂˆâ€â€Ã‚‚ðŒÄ‚ÑÂÂo‚· battle_end_recovery # Œ³‚̃tÆ’FÂÂ[Æ’Y‚TÃ…Â JŽn‚ðŒÄ‚ÑÂÂo‚· battle_end_recovery_original_start_phase5 endend# Battle_End_Recovery# ÂÂ¥£ÂÂÂ¥ XRXS_BP10\. LEVEL UP!Æ’EÆ’Bƒ“ƒhÆ’E ÂÂ¥£ÂÂÂ¥# by ÂÂ÷‰ë ÂÂÓy$data_system_level_up_se = "" # Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’vSEÂÂB""‚Å–³‚µÂÂB$data_system_level_up_me = "Audio/ME/007-Fanfare01" # Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’vME#==============================================================================# ¡ Window_LevelUpWindow#------------------------------------------------------------------------------# ÂÂ@Æ’oÆ’gƒ‹ÂÂIâ€â€Ã‚¹Å½Å¾ÂÂAÆ’Å’Æ’xƒ‹ƒAÆ’bÆ’v‚µ‚½ÂÂꇂɃXÆ’eÂÂ[Æ’^Æ’X‚ð•\Ž¦‚·‚éƒEÆ’Bƒ“ƒhÆ’E‚Å‚·ÂÂB#==============================================================================class Window_LevelUpWindow < Window_Base #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’IÆ’uÆ’WÆ’FÆ’NÆ’g‰Šú‰» #-------------------------------------------------------------------------- def initialize(actor, last_lv, up_hp, up_sp, up_str, up_dex, up_agi, up_int) super(0, 128, 160, 192) self.contents = Bitmap.new(width - 32, height - 32) self.visible = false refresh(actor, last_lv, up_hp, up_sp, up_str, up_dex, up_agi, up_int) end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’Å Æ’tÆ’Å’Æ’bÆ’Vƒ… #-------------------------------------------------------------------------- def refresh(actor, last_lv, up_hp, up_sp, up_str, up_dex, up_agi, up_int) self.contents.clear self.contents.font.color = system_color self.contents.font.name = "Arial" self.contents.font.size = 14 self.contents.draw_text( 0, 0, 160, 24, "LEVEL UP!!") self.contents.font.size = 18 self.contents.draw_text( 0, 28, 160, 24, $data_system.words.hp) self.contents.draw_text( 0, 50, 160, 24, $data_system.words.sp) self.contents.font.size = 14 self.contents.draw_text( 0, 72, 80, 24, $data_system.words.str) self.contents.draw_text( 0, 94, 80, 24, $data_system.words.dex) self.contents.draw_text( 0, 116, 80, 24, $data_system.words.agi) self.contents.draw_text( 0, 138, 80, 24, $data_system.words.int) self.contents.draw_text(92, 0, 128, 24, "¨") self.contents.draw_text(76, 28, 128, 24, "=") self.contents.draw_text(76, 50, 128, 24, "=") self.contents.draw_text(76, 72, 128, 24, "=") self.contents.draw_text(76, 94, 128, 24, "=") self.contents.draw_text(76, 116, 128, 24, "=") self.contents.draw_text(76, 138, 128, 24, "=") self.contents.font.color = normal_color self.contents.draw_text( 0, 0, 88, 24, last_lv.to_s, 2) self.contents.draw_text( 0, 28, 72, 24, "+" + up_hp.to_s, 2) self.contents.draw_text( 0, 50, 72, 24, "+" + up_sp.to_s, 2) self.contents.draw_text( 0, 72, 72, 24, "+" + up_str.to_s, 2) self.contents.draw_text( 0, 94, 72, 24, "+" + up_dex.to_s, 2) self.contents.draw_text( 0, 116, 72, 24, "+" + up_agi.to_s, 2) self.contents.draw_text( 0, 138, 72, 24, "+" + up_int.to_s, 2) self.contents.font.size = 20 self.contents.draw_text( 0, 0, 128, 24, actor.level.to_s, 2) self.contents.draw_text( 0, 26, 128, 24, actor.maxhp.to_s, 2) self.contents.draw_text( 0, 48, 128, 24, actor.maxsp.to_s, 2) self.contents.draw_text( 0, 70, 128, 24, actor.str.to_s, 2) self.contents.draw_text( 0, 92, 128, 24, actor.dex.to_s, 2) self.contents.draw_text( 0, 114, 128, 24, actor.agi.to_s, 2) self.contents.draw_text( 0, 136, 128, 24, actor.int.to_s, 2) endend#==============================================================================# ¡ Window_BattleStatus#==============================================================================class Window_BattleStatus < Window_Base #-------------------------------------------------------------------------- # ÂÂÅ“ ’ljÃÂÂÂEŒöŠJÆ’Cƒ“ƒXÆ’^ƒ“ƒX•Ã†#-------------------------------------------------------------------------- attr_accessor :level_up_flags # LEVEL UP!•\Ž¦end#==============================================================================# ¡ Game_Battler#==============================================================================class Game_Battler #-------------------------------------------------------------------------- # ÂÂÅ“ ’ljÃÂÂÂEŒöŠJÆ’Cƒ“ƒXÆ’^ƒ“ƒX•Ã†#-------------------------------------------------------------------------- attr_accessor :exp_gain_ban # EXPŽæ“¾ˆêŽž‹ÖŽ~ #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’IÆ’uÆ’WÆ’FÆ’NÆ’g‰Šú‰» #-------------------------------------------------------------------------- alias xrxs_bp10_initialize initialize def initialize @exp_gain_ban = false xrxs_bp10_initialize end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’XÆ’eÂÂ[Æ’g [EXP ‚ðŠl“¾‚Å‚«‚È‚¢] â€Â»’è #-------------------------------------------------------------------------- alias xrxs_bp10_cant_get_exp? cant_get_exp? def cant_get_exp? if @exp_gain_ban == true return true else return xrxs_bp10_cant_get_exp? end endend#==============================================================================# ¡ Scene_Battle#==============================================================================class Scene_Battle #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’AÆ’tÆ’^ÂÂ[Æ’oÆ’gƒ‹ƒtÆ’FÂÂ[Æ’YÃ…Â JŽn #-------------------------------------------------------------------------- alias xrxs_bp10_start_phase5 start_phase5 def start_phase5 # EXP Ã…Â l“¾‹ÖŽ~ for i in 0...$game_party.actors.size $game_party.actors[i].exp_gain_ban = true end xrxs_bp10_start_phase5 # EXP Ã…Â l“¾‹ÖŽ~‚̉ðÂÂÅ“ for i in 0...$game_party.actors.size $game_party.actors[i].exp_gain_ban = false end # EXP‚ð‰Šú‰» @exp_gained = 0 for enemy in $game_troop.enemies # Ã…Â l“¾ EXP‚ð’ljà# Æ’GÆ’lÆ’~ÂÂ[‚ª‰B‚êÂÂó‘Ãâ€Ã¢â‚¬Å¡Ãƒâ€¦Ã¢â‚¬Å¡ÃƒË†Ã¢â‚¬Å¡Ã‚¢ÂÂê‡ @exp_gained += enemy.exp if not enemy.hidden end # ÂÂÃÂ’è @phase5_step = 0 @exp_gain_actor = -1 # Æ’Å Æ’Uƒ‹ƒgÆ’EÆ’Bƒ“ƒhÆ’E‚ð•\Ž¦ @result_window.y -= 64 @result_window.visible = true # Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’vâ€Â»’è‚Ö phase5_next_levelup end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’AÆ’tÆ’^ÂÂ[Æ’oÆ’gƒ‹ƒtÆ’FÂÂ[Æ’Y) #-------------------------------------------------------------------------- alias xrxs_bp10_update_phase5 update_phase5 def update_phase5 case @phase5_step when 1 update_phase5_step1 else xrxs_bp10_update_phase5 # Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’v‚µ‚Ä‚¢‚éÂÂꇂ˧ƒoÆ’gƒ‹ÂÂIâ€â€Ã‚¹ battle_end(0) if @levelup_window != nil and @phase5_wait_count <= 0 end end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’AÆ’tÆ’^ÂÂ[Æ’oÆ’gƒ‹ƒtÆ’FÂÂ[Æ’Y 1 : Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’v) #-------------------------------------------------------------------------- def update_phase5_step1 # C Æ’{Æ’^ƒ“‚ª‰Ÿ‚³‚ꂽÂÂê‡ if Input.trigger?(Input::C) # Æ’EÆ’Bƒ“ƒhÆ’E‚ð•Â‚¶‚ÄŽŸ‚̃AÆ’NÆ’^ÂÂ[‚Ö @levelup_window.visible = false if @levelup_window != nil @status_window.level_up_flags[@exp_gain_actor] = false phase5_next_levelup end end #-------------------------------------------------------------------------- # ÂÂÅ“ ŽŸ‚̃AÆ’NÆ’^ÂÂ[‚̃Œƒxƒ‹ƒAÆ’bÆ’v•\Ž¦‚Ö #-------------------------------------------------------------------------- def phase5_next_levelup begin # ŽŸ‚̃AÆ’NÆ’^ÂÂ[‚Ö @exp_gain_actor += 1 # ÂÂÅŒã‚̃AÆ’NÆ’^ÂÂ[‚ÌÂÂê‡ if @exp_gain_actor >= $game_party.actors.size # Æ’AÆ’tÆ’^ÂÂ[Æ’oÆ’gƒ‹ƒtÆ’FÂÂ[Æ’YÃ…Â JŽn @phase5_step = 0 return end actor = $game_party.actors[@exp_gain_actor] if actor.cant_get_exp? == false # Œ»ÂÂÂÌâ€Â\â€â€ÃƒÂ’l‚ð•ÛŽ last_level = actor.level last_maxhp = actor.maxhp last_maxsp = actor.maxsp last_str = actor.str last_dex = actor.dex last_agi = actor.agi last_int = actor.int # Å’oŒ±’lŽæ“¾‚ÌŒˆ’è“IÂÂuÅ Ãâ€(“ä actor.exp += @exp_gained # â€Â»’è if actor.level > last_level # Æ’Å’Æ’xƒ‹ƒAÆ’bÆ’v‚µ‚½ÂÂê‡ @status_window.level_up(@exp_gain_actor) if $data_system_level_up_se != "" Audio.se_stop Audio.se_play($data_system_level_up_se) end if $data_system_level_up_me != "" Audio.me_stop Audio.me_play($data_system_level_up_me) end @levelup_window = Window_LevelUpWindow.new(actor, last_level, actor.maxhp - last_maxhp, actor.maxsp - last_maxsp, actor.str - last_str, actor.dex - last_dex, actor.agi - last_agi, actor.int - last_int) @levelup_window.x = 160 * @exp_gain_actor @levelup_window.visible = true @phase5_wait_count = 40 @phase5_step = 1 # Æ’XÆ’eÂÂ[Æ’^Æ’XÆ’EÆ’Bƒ“ƒhÆ’E‚ðƒŠƒtÆ’Å’Æ’bÆ’Vƒ… @status_window.refresh return end end end until false endend# ÂÂ¥£ÂÂÂ¥ XRXS_17\. Æ’XÆ’Å Æ’bÆ’vÆ’_Æ’ÂÂÂÂ[Æ’W–hΊÂÂ^Œø‰Êâ€â€ÃƒÅ ÂÂÚÂÂ׉» ver.1.51 ÂÂ¥£ÂÂÂ¥# by ÂÂ÷‰ë ÂÂÓy, fukuyama#==============================================================================# ¡ Game_Battler#==============================================================================class Game_Battler #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’XÆ’Å Æ’bÆ’vÆ’_Æ’ÂÂÂÂ[Æ’W‚ÌŒø‰Ê“Kâ€â€p #-------------------------------------------------------------------------- alias xrxs_bp7_slip_damage_effect slip_damage_effect def slip_damage_effect # ÂÂâ€Â’l‚̉Šú‰» slip_damage_percent = 0 slip_damage_plus = 0 # Œ»ÂÂÕt‰Ã‚³‚ê‚Ä‚¢‚éƒXÆ’eÂÂ[Æ’g‚Ì’†‚©‚çƒXÆ’Å Æ’bÆ’vÆ’_Æ’ÂÂÂÂ[Æ’Wâ€â€L‚è‚̃‚ƒm‚ð’T‚· for i in @states if $data_states[i].slip_damage # ‚»‚̃XÆ’eÂÂ[Æ’g‚ªŽÂ‚Ã‚Ă¢‚éƒXÆ’Å Æ’bÆ’vÆ’_Æ’ÂÂÂÂ[Æ’W‚Ì # LvÆ’vƒ‰ƒXÆ’XÆ’eÂÂ[Æ’g‚Ü‚½‚ÃÂLvÆ’}Æ’CÆ’iÆ’XÆ’XÆ’eÂÂ[Æ’g‚ðâ€Â»’èÂÂB for j in $data_states[i].plus_state_set if $data_states[j] != nil if $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)(%|“)/ slip_damage_percent += $1.to_i elsif $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)$/ slip_damage_plus += $1.to_i end end end for j in $data_states[i].minus_state_set if $data_states[j] != nil if $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)(%|“)/ slip_damage_percent -= $1.to_i elsif $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)$/ slip_damage_plus -= $1.to_i end end end end end if slip_damage_percent == 0 and slip_damage_plus == 0 xrxs_bp7_slip_damage_effect else # –h‹ï‚ªƒXÆ’Å Æ’bÆ’v–hŒä‚ª‚ ‚éÂÂꇂðâ€Â»’è for i in [@armor1_id, @armor2_id, @armor3_id, @armor4_id] armor = $data_armors[i] next if armor == nil for j in armor.guard_state_set if $data_states[j] != nil if $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)(%|“)/ if slip_damage_percent > 0 slip_damage_percent = [slip_damage_percent - $1.to_i, 0].max end end if $data_states[j].name =~ /^Æ’XÆ’Å Æ’bÆ’v([0-9]+)$/ if slip_damage_percent > 0 slip_damage_plus = [slip_damage_plus - $1.to_i, 0].max end end end end end # Æ’_Æ’ÂÂÂÂ[Æ’W‚ðÂÂÃÂ’è self.damage = self.maxhp * slip_damage_percent / 100 + slip_damage_plus # •ªŽU if self.damage.abs > 0 amp = [self.damage.abs * 15 / 100, 1].max self.damage += rand(amp+1) + rand(amp+1) - amp end # HP ‚©‚çƒ_Æ’ÂÂÂÂ[Æ’W‚ðŒ¸ŽZ self.hp -= self.damage # Æ’ÂÂÆ’\Æ’bÆ’hÂÂIâ€â€Ã‚¹ return true end endend# ÂÂ¥£ÂÂÂ¥ XRXS_BP 1\. CP§“±“ü ver.15 ÂÂ¥£ÂÂÂ¥# by ÂÂ÷‰ë ÂÂÓy, ËœaŠó, Jack-R#==============================================================================# ¡ Scene_Battle_CP#==============================================================================class Scene_Battle_CP #-------------------------------------------------------------------------- # ÂÂÅ“ ŒöŠJÆ’Cƒ“ƒXÆ’^ƒ“ƒX•Ã†#-------------------------------------------------------------------------- attr_accessor :stop # CP‰ÃÂŽZÆ’XÆ’gÆ’bÆ’v #---------------------------------------------------------------------------- # ÂÂÅ“ Æ’IÆ’uÆ’WÆ’FÆ’NÆ’g‚̉Šú‰» #---------------------------------------------------------------------------- def initialize @battlers = [] @cancel = false @agi_total = 0 # â€Âzâ€â€ÃƒÂ± @count_battlers ‚ð‰Šú‰» @count_battlers = [] # Æ’GÆ’lÆ’~ÂÂ[‚ðâ€Âzâ€â€ÃƒÂ± @count_battlers ‚ɒljàfor enemy in $game_troop.enemies @count_battlers.push(enemy) end # Æ’AÆ’NÆ’^ÂÂ[‚ðâ€Âzâ€â€ÃƒÂ± @count_battlers ‚ɒljàfor actor in $game_party.actors @count_battlers.push(actor) end for battler in @count_battlers @agi_total += battler.agi end for battler in @count_battlers battler.cp = [[65535 * (rand(15) + 85) / 100 * battler.agi / @agi_total * 4, 0].max, 65535].min end end #---------------------------------------------------------------------------- # ÂÂÅ“ CPÆ’JÆ’Eƒ“ƒg‚ÌŠJŽn #---------------------------------------------------------------------------- def start if @cp_thread != nil then return end @cancel = false @stop = false # ‚±‚±‚©‚çƒXÆ’Å’Æ’bÆ’h @cp_thread = Thread.new do while @cancel != true if @stop != true self.update # ÂÂXÂÂV sleep(0.05) end end end # ‚±‚±‚܂ŃXÆ’Å’Æ’bÆ’h end #---------------------------------------------------------------------------- # ÂÂÅ“ CPÆ’JÆ’Eƒ“ƒgÆ’AÆ’bÆ’v #---------------------------------------------------------------------------- def update if @count_battlers != nil then for battler in @count_battlers # ÂÂs“®ÂÂoâ€â€Ã‹â€ ‚È‚¯‚ê‚Ζ³Ž‹ if battler.dead? == true #or battler.movable? == false then battler.cp = 0 next end # ‚±‚±‚Ì 1.3‚ð•Ã‚¦‚邱‚Æ‚Å«ƒXÆ’sÂÂ[Æ’h‚ð•ÃÂÂÂX‰Ââ€Â\ÂÂB‚½‚¾‚µÂ¬ÂÂâ€Â“_‚ÃÂŽgâ€â€p‚·‚邱‚ÆÂÂB battler.cp = [[battler.cp + 1.3 * 4096 * battler.agi / @agi_total, 0].max, 65535].min end end end #---------------------------------------------------------------------------- # ÂÂÅ“ CPÆ’JÆ’Eƒ“ƒg‚ÌŠJŽn #---------------------------------------------------------------------------- def stop @cancel = true if @cp_thread != nil then @cp_thread.join @cp_thread = nil end endend#==============================================================================# ¡ Game_Battler#==============================================================================class Game_Battler attr_accessor :now_guarding # Œ»ÂÂÖhŒä’†ƒtƒ‰ƒO attr_accessor :cp # Œ»ÂÂÃÂCP attr_accessor :slip_state_update_ban # Æ’XÆ’Å Æ’bÆ’vÂÂEÆ’XÆ’eÂÂ[Æ’gŽ©“®Âˆâ€â€Ã‚‚̋֎~ #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’RÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‰Ââ€Â\â€Â»’è #-------------------------------------------------------------------------- def inputable? return (not @hidden and restriction <= 1 and @cp >=65535) end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’XÆ’eÂÂ[Æ’g [Æ’XÆ’Å Æ’bÆ’vÆ’_Æ’ÂÂÂÂ[Æ’W] â€Â»’è #-------------------------------------------------------------------------- alias xrxs_bp1_slip_damage? slip_damage? def slip_damage? return false if @slip_state_update_ban return xrxs_bp1_slip_damage? end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’XÆ’eÂÂ[Æ’gŽ©‘R‰ðÂÂÅ“ (Æ’^ÂÂ[ƒ“‚²‚ƂɌĂÑÂÂo‚µ) #-------------------------------------------------------------------------- alias xrxs_bp1_remove_states_auto remove_states_auto def remove_states_auto return if @slip_state_update_ban xrxs_bp1_remove_states_auto endend#==============================================================================# ¡ Game_Actor#==============================================================================class Game_Actor < Game_Battler #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’ZÆ’bÆ’gÆ’AÆ’bÆ’v #-------------------------------------------------------------------------- alias xrxs_bp1_setup setup def setup(actor_id) xrxs_bp1_setup(actor_id) @hate = 100 # init-value is 100 @cp = 0 @now_guarding = false @slip_state_update_ban = false endend#==============================================================================# ¡ Game_Enemy#==============================================================================class Game_Enemy < Game_Battler #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’IÆ’uÆ’WÆ’FÆ’NÆ’g‰Šú‰» #-------------------------------------------------------------------------- alias xrxs_bp1_initialize initialize def initialize(troop_id, member_index) xrxs_bp1_initialize(troop_id, member_index) @hate = 100 # init-value is 100 @cp = 0 @now_guarding = false @slip_state_update_ban = false endend#==============================================================================# ¡ Window_BattleStatus#==============================================================================class Window_BattleStatus < Window_Base #-------------------------------------------------------------------------- # ÂÂÅ“ ŒöŠJÆ’Cƒ“ƒXÆ’^ƒ“ƒX•Ã†#-------------------------------------------------------------------------- attr_accessor :update_cp_only # CPÆ’ÂÂÂÂ[Æ’^ÂÂ[‚̂ÂÌÂÂXÂÂV #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’IÆ’uÆ’WÆ’FÆ’NÆ’g‰Šú‰» #-------------------------------------------------------------------------- alias xrxs_bp1_initialize initialize def initialize @update_cp_only = false xrxs_bp1_initialize end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’Å Æ’tÆ’Å’Æ’bÆ’Vƒ… #-------------------------------------------------------------------------- alias xrxs_bp1_refresh refresh def refresh if @update_cp_only == false xrxs_bp1_refresh end for i in 0...$game_party.actors.size actor = $game_party.actors[i] actor_x = i * 160 + 4 draw_actor_cp_meter(actor, actor_x, 96, 120, 0) end end #-------------------------------------------------------------------------- # ÂÂÅ“ CPÆ’ÂÂÂÂ[Æ’^ÂÂ[ ‚Ì•`‰æ #-------------------------------------------------------------------------- def draw_actor_cp_meter(actor, x, y, width = 156, type = 0) self.contents.font.color = system_color self.contents.fill_rect(x-1, y+27, width+2,6, Color.new(0, 0, 0, 255)) if actor.cp == nil actor.cp = 0 end w = width * [actor.cp,65535].min / 65535 self.contents.fill_rect(x, y+28, w,1, Color.new(255, 255, 128, 255)) self.contents.fill_rect(x, y+29, w,1, Color.new(255, 255, 0, 255)) self.contents.fill_rect(x, y+30, w,1, Color.new(192, 192, 0, 255)) self.contents.fill_rect(x, y+31, w,1, Color.new(128, 128, 0, 255)) endend#==============================================================================# ¡ Scene_Battle#==============================================================================class Scene_Battle # ‚±‚±‚ÉŒø‰Ê‰¹‚ðÂÂÃÂ’è‚·‚é‚ÆÂÂAÆ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒh‚ªƒ|Æ’bÆ’v‚µ‚½‚Æ‚«‚ÉŒø‰Ê‰¹‚ðÂÂĶ $data_system_command_up_se = "" #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’oÆ’gƒ‹ÂÂIâ€â€Ã‚¹ # result : Œ‹‰Ê(0:Ÿâ€â€Ã‹Å“ 1:â€Âs–k 2:“¦‘–) #-------------------------------------------------------------------------- alias xrxs_bp1_battle_end battle_end def battle_end(result) # CPÆ’JÆ’Eƒ“ƒg’âŽ~ @cp_thread.stop xrxs_bp1_battle_end(result) end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’vÆ’Å’Æ’oÆ’gƒ‹ƒtÆ’FÂÂ[Æ’YÃ…Â JŽn #-------------------------------------------------------------------------- alias xrxs_bp1_start_phase1 start_phase1 def start_phase1 @agi_total = 0 @cp_thread = Scene_Battle_CP.new # Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚ðÂÂÄÂÂì¬ s1 = $data_system.words.attack s2 = $data_system.words.skill s3 = $data_system.words.guard s4 = $data_system.words.item @actor_command_window = Window_Command.new(160, [s1, s2, s3, s4, "Run"]) @actor_command_window.y = 128 @actor_command_window.back_opacity = 160 @actor_command_window.active = false @actor_command_window.visible = false @actor_command_window.draw_item(4, $game_temp.battle_can_escape ? @actor_command_window.normal_color : @actor_command_window.disabled_color) xrxs_bp1_start_phase1 end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’pÂÂ[Æ’eÆ’BÆ’RÆ’}ƒ“ƒhÆ’tÆ’FÂÂ[Æ’YÃ…Â JŽn #-------------------------------------------------------------------------- alias xrxs_bp1_start_phase2 start_phase2 def start_phase2 xrxs_bp1_start_phase2 @party_command_window.active = false @party_command_window.visible = false # ŽŸ‚Ö start_phase3 end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’pÂÂ[Æ’eÆ’BÆ’RÆ’}ƒ“ƒhÆ’tÆ’FÂÂ[Æ’Y) #-------------------------------------------------------------------------- alias xrxs_bp1_update_phase2 update_phase2 def update_phase2 # C Æ’{Æ’^ƒ“‚ª‰Ÿ‚³‚ꂽÂÂê‡ if Input.trigger?(Input::C) # Æ’pÂÂ[Æ’eÆ’BÆ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚̃JÂÂ[Æ’\ƒ‹ˆÊ’u‚Å•ªŠò case @party_command_window.index when 0 # ¤ # Œˆ’è SE ‚ð‰‰‘t $game_system.se_play($data_system.decision_se) @cp_thread.start # Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’tÆ’FÂÂ[Æ’YÃ…Â JŽn start_phase3 end return end xrxs_bp1_update_phase2 end #-------------------------------------------------------------------------- # ÂÂÅ“ ŽŸ‚̃AÆ’NÆ’^ÂÂ[‚̃RÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‚Ö #-------------------------------------------------------------------------- def phase3_next_actor # ƒ‹ÂÂ[Æ’v begin # Æ’AÆ’NÆ’^ÂÂ[‚Ì–¾–ŃGÆ’tÆ’FÆ’NÆ’g OFF if @active_battler != nil @active_battler.blink = false end # ÂÂÅŒã‚̃AÆ’NÆ’^ÂÂ[‚ÌÂÂê‡ if @actor_index == $game_party.actors.size-1 # Æ’ÂÂÆ’Cƒ“ƒtÆ’FÂÂ[Æ’YÃ…Â JŽn @cp_thread.start start_phase4 return end # Æ’AÆ’NÆ’^ÂÂ[‚̃Cƒ“ƒfÆ’bÆ’NÆ’X‚ðÂÂi‚ß‚é @actor_index += 1 @active_battler = $game_party.actors[@actor_index] @active_battler.blink = true if @active_battler.inputable? == false @active_battler.current_action.kind = -1 end # Æ’AÆ’NÆ’^ÂÂ[‚ªƒRÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‚ðŽó‚¯•t‚¯‚È‚¢ÂÂó‘Ãâ€Ã¢â‚¬Å¡ÃƒË†Ã¢â‚¬Å¡ÃƒÂ§Ã¢â‚¬Å¡ÃƒÂ ‚¤ˆê“x end until @active_battler.inputable? @cp_thread.stop # Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚ðƒZÆ’bÆ’gÆ’AÆ’bÆ’v @active_battler.now_guarding = false phase3_setup_command_window end #-------------------------------------------------------------------------- # ÂÂÅ“ ‘O‚̃AÆ’NÆ’^ÂÂ[‚̃RÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‚Ö #-------------------------------------------------------------------------- def phase3_prior_actor # ƒ‹ÂÂ[Æ’v begin # Æ’AÆ’NÆ’^ÂÂ[‚Ì–¾–ŃGÆ’tÆ’FÆ’NÆ’g OFF if @active_battler != nil @active_battler.blink = false end # ÂÂʼn‚̃AÆ’NÆ’^ÂÂ[‚ÌÂÂê‡ if @actor_index == 0 # ÂÂʼn‚Ö–ß‚é start_phase3 return end # Æ’AÆ’NÆ’^ÂÂ[‚̃Cƒ“ƒfÆ’bÆ’NÆ’X‚ð–ß‚· @actor_index -= 1 @active_battler = $game_party.actors[@actor_index] @active_battler.blink = true # Æ’AÆ’NÆ’^ÂÂ[‚ªƒRÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‚ðŽó‚¯•t‚¯‚È‚¢ÂÂó‘Ãâ€Ã¢â‚¬Å¡ÃƒË†Ã¢â‚¬Å¡ÃƒÂ§Ã¢â‚¬Å¡ÃƒÂ ‚¤ˆê“x end until @active_battler.inputable? @cp_thread.stop # Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚ðƒZÆ’bÆ’gÆ’AÆ’bÆ’v @active_battler.now_guarding = false phase3_setup_command_window end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚̃ZÆ’bÆ’gÆ’AÆ’bÆ’v #-------------------------------------------------------------------------- alias xrxs_bp1_phase3_setup_command_window phase3_setup_command_window def phase3_setup_command_window # Œø‰Ê‰¹‚ÌÂÂĶ Audio.se_play($data_system_command_up_se) if $data_system_command_up_se != "" # –ß‚· xrxs_bp1_phase3_setup_command_window end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’tÆ’FÂÂ[Æ’Y : Šî–{Æ’RÆ’}ƒ“ƒh) #-------------------------------------------------------------------------- alias xrxs_bsp1_update_phase3_basic_command update_phase3_basic_command def update_phase3_basic_command # C Æ’{Æ’^ƒ“‚ª‰Ÿ‚³‚ꂽÂÂê‡ if Input.trigger?(Input::C) # Æ’AÆ’NÆ’^ÂÂ[Æ’RÆ’}ƒ“ƒhÆ’EÆ’Bƒ“ƒhÆ’E‚̃JÂÂ[Æ’\ƒ‹ˆÊ’u‚Å•ªŠò case @actor_command_window.index when 4 # “¦‚°‚é if $game_temp.battle_can_escape # Œˆ’è SE ‚ð‰‰‘t $game_system.se_play($data_system.decision_se) # Æ’AÆ’NÆ’Vƒ‡ƒ“‚ðÂÂÃÂ’è @active_battler.current_action.kind = 0 @active_battler.current_action.basic = 4 # ŽŸ‚̃AÆ’NÆ’^ÂÂ[‚̃RÆ’}ƒ“ƒh“üâ€â€ÃƒÂ‚Ö phase3_next_actor else # Æ’uÆ’UÂÂ[ SE ‚ð‰‰‘t $game_system.se_play($data_system.buzzer_se) end return end end xrxs_bsp1_update_phase3_basic_command end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’ÂÂÆ’Cƒ“ƒtÆ’FÂÂ[Æ’YÃ…Â JŽn #-------------------------------------------------------------------------- alias xrxs_bp1_start_phase4 start_phase4 def start_phase4 xrxs_bp1_start_phase4 # Æ’GÆ’lÆ’~ÂÂ[Æ’AÆ’NÆ’Vƒ‡ƒ“ÂÂì¬ for enemy in $game_troop.enemies if enemy.cp < 65535 enemy.current_action.clear enemy.current_action.kind = -1 # Æ’^ÂÂ[ƒ“â€Âò‚΂µÂÂB next end enemy.make_action end # ÂÂs“®Â‡ÂÂËœÂÂì¬ make_action_orders end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’ÂÂÆ’Cƒ“ƒtÆ’FÂÂ[Æ’Y Æ’XÆ’eÆ’bÆ’v 1 : Æ’AÆ’NÆ’Vƒ‡ƒ“€â€Âõ) #-------------------------------------------------------------------------- alias xrxs_bp1_update_phase4_step1 update_phase4_step1 def update_phase4_step1 # ‰Šú‰» @phase4_act_continuation = 0 # Ÿâ€Âsâ€Â»’è if judge @cp_thread.stop # Ÿâ€â€Ã‹Å“‚Ü‚½‚ÃÂâ€Âs–k‚ÌÂÂê‡ : Æ’ÂÂÆ’\Æ’bÆ’hÂÂIâ€â€Ã‚¹ return end # –¢ÂÂs“®ƒoÆ’gƒ‰ÂÂ[â€Âzâ€â€ÃƒÂ±Ã¢â‚¬Å¡ÃƒÅ’ÂÂ擪‚©‚çŽæ“¾ @active_battler = @action_battlers[0] # Æ’XÆ’eÂÂ[Æ’^Æ’XÂÂXÂÂV‚ðCP‚¾‚¯‚ÉŒÀ’èÂÂB @status_window.update_cp_only = true # Æ’XÆ’eÂÂ[Æ’gÂÂXÂÂV‚ð‹ÖŽ~ÂÂB @active_battler.slip_state_update_ban = true if @active_battler != nil # –ß‚· xrxs_bp1_update_phase4_step1 # ‹ÖŽ~‚ð‰ðÂÂÅ“ @status_window.update_cp_only = false @active_battler.slip_state_update_ban = false if @active_battler != nil end #-------------------------------------------------------------------------- # ÂÂÅ“ Æ’tÆ’Å’ÂÂ[ƒ€ÂÂXÂÂV (Æ’ÂÂÆ’Cƒ“ƒtÆ’FÂÂ[Æ’Y Æ’XÆ’eÆ’bÆ’v 2 : Æ’AÆ’NÆ’Vƒ‡ƒ“ŠJŽn) #-------------------------------------------------------------------------- alias xrxs_bp1_update_phase4_step2 update_phase4_step2 def update_phase4_step2 # ‹Â§ƒAÆ’NÆ’Vƒ‡ƒ“‚Å‚È‚¯‚ê‚Î unless @active_battler.current_action.forcing # CP‚ª‘«‚è‚Ä‚¢‚È‚¢ÂÂê‡ if @phase4_act_continuation == 0 and @active_battler.cp < 65535 @phase4_step = 6 return end # §–ñ‚ª [“G‚ð’ÊÂÂÃÂÂÂUŒ‚‚·‚é] ‚© [–¡•û‚ð’ÊÂÂÃÂÂÂUŒ‚‚·‚é] ‚ÌÂÂê‡ if @active_battler.restriction == 2 or @active_battler.restriction == 3 # Æ’AÆ’NÆ’Vƒ‡ƒ“‚ÉÂÂUŒ‚‚ðÂÂÃÂ’è @active_battler.current_action.kind = 0 @active_battler.current_action.basic = 0 end # §–ñ‚ª [ÂÂs“®‚Å‚«‚È‚¢] ‚ÌÂÂê‡ if @active_battler.restriction == 4 # Æ’AÆ’NÆ’Vƒ‡ƒ“‹Â§‘ÎÂÂۂ̃oÆ’gƒ‰ÂÂ[‚ðƒNÆ’Å Æ’A $game_temp.forcing_battler = nil if @phase4_act_continuation == 0 and @active_battler.cp >= 65535 # Æ’XÆ’eÂÂ[Æ’gŽ©‘R‰ðÂÂÅ“ @active_battler.remove_states_auto # CPÂÂÃÂâ€Âï @active_battler.cp = [(@active_battler.cp - 65535),0].max # Æ’XÆ’eÂÂ[Æ’^Æ’XÆ’EÆ’Bƒ“ƒhÆ’E‚ðƒŠƒtÆ’Å’Æ’bÆ’Vƒ… @status_window.refresh end # Æ’XÆ’eÆ’bÆ’v 1 ‚ɈÚÂÂs @phase4_step = 1 return end end # Æ’AÆ’NÆ’Vƒ‡ƒ“‚̎ÕʂŕªŠò case @active_battler.current_action.kind when 0 # ÂÂUŒ‚¥–hΊÂÂE“¦‚°‚éÂÂE‰½‚à‚µ‚È‚¢Žž‚Ì‹¤’ÊÂÂÃÂâ€ÂïCP @active_battler.cp -= 0 if @phase4_act_continuation == 0 when 1 # Æ’XÆ’Lƒ‹Žgâ€â€pŽž‚ÌÂÂÃÂâ€ÂïCP @active_battler.cp -= 65535 if @phase4_act_continuation == 0 when 2 # Æ’AÆ’CÆ’eƒ€Žgâ€â€pŽž‚ÌÂÂÃÂâ€ÂïCP @active_battler.cp -= 65535 if @phase4_act_continuation == 0 when -1 # CP‚ªâ€â€Ã‚‚܂Ã‚Ă¢‚È‚¢ @phase4_step = 6 return end # CP‰ÃÂŽZ‚ðˆêŽž’âŽ~‚·‚é @cp_thread.stop = true # Æ’XÆ’eÂÂ[Æ’gŽ©‘R‰ðÂÂÅ“ @active_battler.remove_states_auto xrxs_bp1_update_phase4_step2 end #-------------------------------------------------------------------------- # ÂÂÅ“ Šî–{Æ’AÆ’NÆ’Vƒ‡ƒ“ Œ‹‰ÊÂÂì¬ #-------------------------------------------------------------------------- alias xrxs_bp1_make_basic_action_result make_basic_action_result def make_basic_action_result # ÂÂUŒ‚‚ÌÂÂê‡ if @active_battler.current_action.basic == 0 and @phase4_act_continuation == 0 @active_battler.cp -= 65535 # ÂÂUŒ‚Žž‚ÌCPÂÂÃÂâ€Âï end # –hŒä‚ÌÂÂê‡ if @active_battler.current_action.basic == 1 and @phase4_act_continuation == 0 @active_battler.cp -= 32767 # –hÅ’[/i][/i][/i][/i][/i][/i][/i]``` Link to comment Share on other sites More sharing options...
Kirby Lord Posted December 15, 2009 Share Posted December 15, 2009 I don't think half of those are commands. But I'm not a scripting expert so don't take my word for it. Link to comment Share on other sites More sharing options...
SHADERS Posted December 15, 2009 Author Share Posted December 15, 2009 @Kirby:> I don't think half of those are commands. But I'm not a scripting expert so don't take my word for it.i know. but i found this script floating around and it is a battling system script and it seemed like it would work but i am at school right now and i cant really try it. also, i wanted to know if it is usable or not… Link to comment Share on other sites More sharing options...
Kirby Lord Posted December 15, 2009 Share Posted December 15, 2009 It's probably for another engine or something like that. Eclipse uses Sadscript in the current version. I don't know what kind that is but I'm pretty sure it's not what Eclipse uses. Link to comment Share on other sites More sharing options...
Sowether Posted December 15, 2009 Share Posted December 15, 2009 No, it won't work.You can't just catch any script in the internet and put in ecplise. Link to comment Share on other sites More sharing options...
teh jimpie Posted December 15, 2009 Share Posted December 15, 2009 I don't think this will work, the 'server' wont understand that XD same as you put:```'This script kills other player:Case 1adsfkjasdlkfjsad;lkgjfsdg;ljkfdsgl;sfkdjgldsfgsdfgfdgolifdsjhglkesdfhgdsfgfgsdfigjsfd;lkgjdsfgfsdExit Sub```lol :P Link to comment Share on other sites More sharing options...
Robin Posted December 15, 2009 Share Posted December 15, 2009 It's a Ruby script, probably used in RMVX or RMXP.This won't work in Eclipse as Eclipse uses Sadscript with it's own custom functions.It's also not OOP. xD Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now