Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module FFS
- module RNG
- MAX = 10 # Es wird eine Zahl zwischen 0 und MAX generiert
- BELOW = 2 # Es wird geprüft, ob die generierte Zahl kleiner
- # oder gleich als BELOW ist.
- end
- end
- #==============================================================================
- # ** Game_Actor
- #------------------------------------------------------------------------------
- # This class handles actors. It is used within the Game_Actors class
- # ($game_actors) and is also referenced from the Game_Party class ($game_party).
- #==============================================================================
- class Game_Actor < Game_Battler
- #--------------------------------------------------------------------------
- # * Aliased Method: [HP Recovery] Effect
- #--------------------------------------------------------------------------
- alias :ffs_item_effect_recover_hp :item_effect_recover_hp
- def item_effect_recover_hp( *args )
- num = rand(FFS::RNG::MAX)
- if args[0] != self && !(num <= FFS::RNG::BELOW)
- DiamondandPlatinum3::BattleVoices::play_healed_voice(@actor_id)
- end
- # Call Original Method
- ffs_item_effect_recover_hp( *args )
- end
- #--------------------------------------------------------------------------
- # * Aliased Method: [MP Recovery] Effect
- #--------------------------------------------------------------------------
- alias :ffs_item_effec_recover_mp :item_effect_recover_mp
- def item_effect_recover_mp( *args )
- num = rand(FFS::RNG::MAX)
- if args[0] != self && !(num <= FFS::RNG::BELOW)
- DiamondandPlatinum3::BattleVoices::play_healed_voice(@actor_id)
- end
- # Call Original Method
- ffs_item_effect_recover_mp( *args )
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement