02-08-2014, 02:19 PM
(02-08-2014, 04:24 AM)DerVVulfman Wrote: The damage pop uses a few values to see if a battler has a damage pop and sends it into my damage pop system. IF your Drain/Osmosis script performs changes to the Game_Battler class, you need very few changes if you're using this one too.The Draining script does modify the Game_Battler class:
The SP damage system adds @dvv_sp_damage_pop (a boolean or true/false/nil) value to see if the actor needs a SP damage pop to show, and @dvv_sp_damage, which holds the value of SP damage (nil by default). And, it sends the value to the Damage Pop sprite system by using self.dvv_sp_damage much the same way as self.damage is used to send damage values to the default pop system.
Just look at the Initialize and the end of the skill_effect methods in the Simple SP Damage script.
Code:
#==============================================================================
# ** Game_Battler
#------------------------------------------------------------------------------
# This class deals with battlers. It's used as a superclass for the Game_Actor
# and Game_Enemy classes.
#==============================================================================
class Game_Battler
#--------------------------------------------------------------------------
# * Apply Skill Effects
# user : the one using skills (battler)
# skill : skill
#--------------------------------------------------------------------------
alias has_skill_effect skill_effect
def skill_effect(user, skill, dilute = 1)
# Original call
effective = has_skill_effect(user, skill)
# Set hook to damage
if self.damage.is_a?(Numeric)
$game_temp.damage_hook += self.damage
end
# End Method
return effective
end
end
I really ought to learn about coding stuff.