#==============================================================================# ■ Meow Face Extra Battle Bonuses#------------------------------------------------------------------------------# Double Exp/Gold based on Actor's Luck/Dex#==============================================================================# How to Use:# [1] Plug & Play, Put this script below Material and above other custom scripts# [2] For the actors you want to have this special ability# Add <EXTRAEXP> or <extra exp> in the actor's note tag for extra exp based on luck# Add <EXTRAGOLD> or <extra gold> in the actor's note tag for extra gold based on dex#==============================================================================# Edit Anything Pass This Line at Your Own Risk!#==============================================================================#--------------------------------------------------------------------------# ○ Starting of New Methods#--------------------------------------------------------------------------class RPG::Actor < RPG::BaseItem def expex return true if @note[/<(?:EXTRAEXP|extra exp)>/i] return false end def goldex return true if @note[/<(?:EXTRAGOLD|extra gold)>/i] return false end endclass Game_Actor < Game_Battler def ex_exp? actor.expex end def ex_gold? actor.goldex endendclass Game_Troop < Game_Unit def get_battle_member_luck @total_luk = 0 $game_party.battle_members.each do |m| if m.ex_exp? @total_luk += m.luk end end return @total_luk/100 if @total_luk != nil end def get_battle_member_dex @total_agi = 0 $game_party.battle_members.each do |m| if m.ex_gold? @total_agi += m.agi end end return @total_agi/100 if @total_agi != nil end def exp_extra? @ex_exp_rate = get_battle_member_luck @rate = rand(100)+1 return true if @rate <= @ex_exp_rate return false end def gold_extra? @ex_gold_rate = get_battle_member_dex @rate = rand(100)+1 return true if @rate <= @ex_gold_rate return false endend#--------------------------------------------------------------------------# ○ End of New Methods#--------------------------------------------------------------------------module BattleManager#--------------------------------------------------------------------------# ◎ Starting of Alias Methods#-------------------------------------------------------------------------- class <<self alias meow_setup setup end def self.setup(troop_id, can_escape = true, can_lose = false) meow_setup(troop_id, can_escape = true, can_lose = false) @extraexp = $game_troop.exp_extra? @extragold = $game_troop.gold_extra? end#--------------------------------------------------------------------------# ◎ End of Alias Methods#--------------------------------------------------------------------------#--------------------------------------------------------------------------# ● Starting of Overwrite Methods#-------------------------------------------------------------------------- def self.display_exp if $game_troop.exp_total > 0 earn = $game_troop.exp_total earn *= 2 if @extraexp text = sprintf(Vocab::ObtainExp, earn) $game_message.add('\.' + "Double Exp Gained!") if @extraexp $game_message.add('\.' + text) end end def self.gain_gold if $game_troop.gold_total > 0 earn = $game_troop.gold_total earn *= 2 if @extragold text = sprintf(Vocab::ObtainGold, earn) $game_message.add('\.' + "Double Gold Income!") if @extragold $game_message.add('\.' + text) $game_party.gain_gold(earn) end wait_for_message end def self.gain_exp earn = $game_troop.exp_total earn *= 2 if @extraexp $game_party.all_members.each do |actor| actor.gain_exp(earn) end wait_for_message endend#--------------------------------------------------------------------------# ● End of Overwrite Methods#--------------------------------------------------------------------------