HoT DoT
Authors: shdwlink1993, KK20
Version: 1.04
Type: Poison Control
Key Term: Player / Party / Troop Add-on
IntroductionHoT DoT (Apparantly WoW-speak for Healing/Damage over Time), or Poison Control, is a system designed to let you make poison do more than what it always does. In RMXP and RMVX, poison does one thing only. That can be annoying after a while, like having a recharging health stat, or draining your magic.
Features
- Allows for many kinds of poison.
- Poisons that can heal you can easily be made.
- Lets poisons affect other stats besides health.
- More than one poison affects you at a time.
ScreenshotsThese would be completely useless.
DemoThe script is pretty plug-and-play, so I don't think this is needed.
Script1.04 by KK20#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.04
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
# HT Date 1.04: 4/08/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
# Version 1.04 ---------------------------------------------------- [4/08/2012]
#
# V 1.04 Changes:
# - DoT that heals will make the screen flash green instead of red
# - Damage values that were displayed in battle were inaccurate
# - Percentage based damage was written incorrectly
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 100, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
sp_damage = 0
self.damage = 0
# Get the HoT/DoT states applied to the character
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = self.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = self.maxsp * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = @hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.hp = [hp - damage,1].max # Leave 1 HP
else
self.hp -= damage
end
# Add total damage to variable
self.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = @sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.sp = [sp - damage,1].max # Leave 1 SP
else
self.sp -= damage
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
self.damage = sp_damage if self.damage == 0
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
if actor.damage <= 0
# Positive DoT makes green screen
$game_screen.start_flash(Color.new(0, 255, 0, 128), 4)
else
# Negative DoT makes red screen
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
end
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
1.01b by shdwlink (has a few bugs)
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.01b
# Type: Poison Control
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# - A simple math error was fixed (+ instead of -)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if the type was positive (~5 HP difference)
# or negative (~5% HP difference).
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
self.damage = SL93.hotdot(i)[1] if SL93.hotdot(i)[0] > 0
self.damage = self.maxhp / SL93.hotdot(i)[1] if SL93.hotdot(i)[0] == -1
self.damage = self.maxsp / SL93.hotdot(i)[1] if SL93.hotdot(i)[0] == -2
if self.damage.abs > 0 && SL93.hotdot(i)[2] > 0
amp = [self.damage.abs - SL93.hotdot(i)[2], 1].max if SL93.hotdot(i)[0] > 0
amp = [self.damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
self.damage += rand(amp+1) + rand(amp+1) - amp
end
self.damage = self.damage * -1 if SL93.hotdot(i)[0] < 0
if SL93.hotdot(i)[0] == 1 || SL93.hotdot(i)[0] == -1
self.damage = self.hp - 1 if !SL93.hotdot(i)[3] && (0 > self.hp += self.damage)
self.hp += self.damage
elsif SL93.hotdot(i)[0] == 2 || SL93.hotdot(i)[0] == -2
self.damage = self.sp - 1 if !SL93.hotdot(i)[3] && (0 > self.sp += self.damage)
self.sp += self.damage
end
end
return true
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
InstructionsFound within the script.
Compatibility
- Low probability of working with the SDK.
- Will not work with other Poison-editing scripts.
- Must be placed above Tons of Addons.
Credits and Thanks
- Arxur for the script idea.
Author's NotesA VX version is available here. (http://forum.chaos-project.com/index.php?topic=2482.0)
EDIT: Fixed a very stupid problem in the documentation (And a very stupid error in the script itself - I fixed it in time for VX though.). xD
Nice job and this looks compatible with BABS too! i'll test it out to make sure. Definitely a useful script:)
yay! Awesome stuff *power up*
So is this compatible with BABS?
I wanted to know before using it.
@game_guy: It really should be compatible with Blizz-ABS.
@Kagutsuchi + Winkio: Thanks! :D
Would this need a plugin for RMX-OS to make the effects 'global' or not?
I've been having a small problem with this script.
As mentioned in the script, a "-" in front of the second value,
will cause the amount to be healing in stead of damage.
But when I made a state that is supposed to heal (ofcourse using the "-"),
it does damage anyway.
The odd thing about it, is that the damage appears as green (which is normally healing).
I guess it's just a simple math error, but I couldn't figure out the cause myself.
Anybody mind giving me a hand?
It's a small script, so spotting the issue shouldn't be hard for someone with experience with ruby.
Actually, there were a few more bugs with this script than what you said. I went ahead and fixed them.
The following is updated to Version 1.02.#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.02
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Fixed:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if the type was positive (~5 HP difference)
# or negative (~5% HP difference).
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
self.damage = SL93.hotdot(i)[1] if SL93.hotdot(i)[0] > 0
self.damage = self.maxhp / SL93.hotdot(i)[1] if SL93.hotdot(i)[0] == -1
self.damage = self.maxsp / SL93.hotdot(i)[1] if SL93.hotdot(i)[0] == -2
if self.damage.abs > 0 && SL93.hotdot(i)[2] > 0
amp = [self.damage.abs - SL93.hotdot(i)[2], 1].max if SL93.hotdot(i)[0] > 0
amp = [self.damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
self.damage += rand(amp+1) + rand(amp+1) - amp
end
self.damage = self.damage * -1 if SL93.hotdot(i)[0] < 0
if SL93.hotdot(i)[0] == 1 || SL93.hotdot(i)[0] == -1
hp = @hp
# If limit_drain and actual damage being done (not healing)
if SL93.hotdot(i)[3] and self.damage > 0
self.hp = [hp - self.damage,1].max
else
self.hp -= self.damage
end
elsif SL93.hotdot(i)[0] == 2 || SL93.hotdot(i)[0] == -2
sp = @sp
if SL93.hotdot(i)[3] and self.damage > 0
self.sp = [sp - self.damage,1].max
else
self.sp -= self.damage
end
end
end
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
Great, thanks a lot for the fixes.
Noticed the third bug as well, but I just ignored it by halving the values,
but this is better :)
EDIT:
I noticed another bug, or new bug actually.
This is the configuration part of the script:
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if the type was positive (~5 HP difference)
# or negative (~5% HP difference).
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 10, 15, false] # Standard Poison
As mentioned in the instructions, when the first value is negative the second value will be used as a percentage,
while when positive, it will be used as a literal number.
But, since the update, when making the first value negative,
it turns the damage into healing (which isn't supposed to happen, but only when the SECOND value is negative).
Not an issue that is a big bother on my part, but I figured I'd mention it.
Hah, didn't see that edit until now. Changes listed in log.
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.03
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
# [** NOTE **]
# If VARIANCE > DAMAGE, the script will change VARIANCE to 1.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
# Get the HoT/DoT states applied to the character
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
self.damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
self.damage = self.maxhp / SL93.hotdot(i)[1]
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
self.damage = self.maxsp / SL93.hotdot(i)[1]
end
# If damage/heal amount is not zero and variance exists
if self.damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (self.damage.abs < SL93.hotdot(i)[2] ? 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [self.damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
self.damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = @hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and self.damage > 0
self.hp = [hp - self.damage,1].max # Leave 1 HP
else
self.hp -= self.damage
end
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = @sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and self.damage > 0
self.sp = [sp - self.damage,1].max # Leave 1 SP
else
self.sp -= self.damage
end
end
end
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
Quote from: KK20 on March 21, 2012, 12:59:01 am
Hah, didn't see that edit until now. Changes listed in log.
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.03
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
# [** NOTE **]
# If VARIANCE > DAMAGE, the script will change VARIANCE to 1.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
# Get the HoT/DoT states applied to the character
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
self.damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
self.damage = self.maxhp / SL93.hotdot(i)[1]
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
self.damage = self.maxsp / SL93.hotdot(i)[1]
end
# If damage/heal amount is not zero and variance exists
if self.damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (self.damage.abs < SL93.hotdot(i)[2] ? 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [self.damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
self.damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = @hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and self.damage > 0
self.hp = [hp - self.damage,1].max # Leave 1 HP
else
self.hp -= self.damage
end
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = @sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and self.damage > 0
self.sp = [sp - self.damage,1].max # Leave 1 SP
else
self.sp -= self.damage
end
end
end
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
Nice job, I modified the first post and put your edit in there. :3
Thanks for the bug fixes :) I know this is kind of cosmetic...but is there a way that negative states that actually cause damage will have a red screen flash while those that are positive(healing) have a blue or green screen flash? Currently, all states that are affected by HoT DoT put out a red flash while walking. Just curious :)
Noticed a couple more things I missed. Updated to Version 1.04:
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.04
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
# HT Date 1.04: 4/08/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
# Version 1.04 ---------------------------------------------------- [4/08/2012]
#
# V 1.04 Changes:
# - DoT that heals will make the screen flash green instead of red
# - Damage values that were displayed in battle were inaccurate
# - Percentage based damage was written incorrectly
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
#------------------------------------------------------------------------
when 3 then return [-1, 100, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
sp_damage = 0
self.damage = 0
# Get the HoT/DoT states applied to the character
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = self.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = self.maxsp * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = @hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.hp = [hp - damage,1].max # Leave 1 HP
else
self.hp -= damage
end
# Add total damage to variable
self.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = @sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.sp = [sp - damage,1].max # Leave 1 SP
else
self.sp -= damage
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
self.damage = sp_damage if self.damage == 0
end
end
class Game_Party
def check_map_slip_damage
@actors.each {|actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
if actor.damage <= 0
# Positive DoT makes green screen
$game_screen.start_flash(Color.new(0, 255, 0, 128), 4)
else
# Negative DoT makes red screen
$game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
end
$game_temp.gameover = $game_party.all_dead?
end
}
end
end
I don't know if I'm doing something wrong.
I've tried this script 2 times now and I just cant manage to figure it out.
any idea of what I'm doing wrong?
So i want to create a "Slip Damage" that can do more damage than the standard option (as well as heals). I found this script because i failed at mod-ing the standard code to work how i wanted it.
Like i said i've used it 2 times and cant manage to get it to work
Leaving the stock venom as 3....No matter how I mod the code....
Quote
when 3 then return [ 1, 50, 15, false] # Standard Poison
I cant make it actually change the damage on the "Slip Damage".
I turned Slip damage on and off from the venom state. it will still tick at a 1/100 rate (par to stock) regardless.
but it just wont follow the code.
I understand the instructions in the code. i followed them.. i also moded them to huge numbers. still to only see 1/100...
Im not using ANY battle mods or poison mods other than BABS. but others say it works with BABS.
The script is placed under BABS.
Any help would be appreciated :D thanks friends!
Actually, upon further insight, this script is not compatible with Blizz-ABS. Slip damage in BABS takes place under the class
Map_Battler while this script takes place in class
Game_Battler. Replace the class with this:
class Map_Battler < Game_Character
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
sp_damage = 0
self.battler.damage = 0
# Get the HoT/DoT states applied to the character
for i in battler.states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = self.battler.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = self.battler.maxsp * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = self.battler.hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.battler.hp = [hp - damage,1].max # Leave 1 HP
else
self.battler.hp -= damage
end
# Add total damage to variable
self.battler.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = self.battler.sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.battler.sp = [sp - damage,1].max # Leave 1 SP
else
self.battler.sp -= damage
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
self.battler.damage = sp_damage if self.battler.damage == 0
end
end
KK to the rescue! sorry I didn't reply sooner.
the code worked for the literal numbers such as losing a consistent -10 HP every time. But this wont cause a scaling skill that i'm trying to get. so i tried the percent ability to the script.
but when i used a percent it kept giving me errors. not sure whats up.
the error says NoMethodError occurred.
undefined method 'maxhp' for#<Map_Enemy:0x9127c08>
the line that has the error is probably different than your code so ill link the direct line it says
damage = self.maxhp * SL93.hotdot(i)[1] / 100
Ill play with it some more tomorrow if you don't get to it first.
Thanks for the help :D
My bad. On that line and somewhere below it for 'maxsp', make it
self.battler.maxhp
self.battler.maxsp
KK20! lots of love friend!
Thanks for that. it works beautifully.
For others looking for the code that works with BABS here it is
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.04
# Type: Poison Control
#
# Editted by KK20
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
# HT Date 1.04: 4/08/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
# Version 1.04 ---------------------------------------------------- [4/08/2012]
#
# V 1.04 Changes:
# - DoT that heals will make the screen flash green instead of red
# - Damage values that were displayed in battle were inaccurate
# - Percentage based damage was written incorrectly
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
#
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
#
#------------------------------------------------------------------------
when 3 then return [ -1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
class Game_Battler
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
sp_damage = 0
self.damage = 0
# Get the HoT/DoT states applied to the character
for i in @states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = self.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = self.maxsp * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = @hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.hp = [hp - damage,1].max # Leave 1 HP
else
self.hp -= damage
end
# Add total damage to variable
self.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = @sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.sp = [sp - damage,1].max # Leave 1 SP
else
self.sp -= damage
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
self.damage = sp_damage if self.damage == 0
end
end
class Map_Battler < Game_Character
def slip_damage?
return @states.any? {|i| SL93.hotdot(i) != false }
end
def slip_damage_effect
ids = []
sp_damage = 0
self.battler.damage = 0
# Get the HoT/DoT states applied to the character
for i in battler.states
ids.push(i) if SL93.hotdot(i) != false
end
for i in ids
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = self.battler.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = self.battler.maxsp * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = self.battler.hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.battler.hp = [hp - damage,1].max # Leave 1 HP
else
self.battler.hp -= damage
end
# Add total damage to variable
self.battler.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = self.battler.sp
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
self.battler.sp = [sp - damage,1].max # Leave 1 SP
else
self.battler.sp -= damage
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
self.battler.damage = sp_damage if self.battler.damage == 0
end
end
#class Game_Party
# def check_map_slip_damage
# @actors.each {|actor|
# if actor.hp > 0 && actor.slip_damage?
# actor.slip_damage_effect
# if actor.damage <= 0
# # Positive DoT makes green screen
# $game_screen.start_flash(Color.new(0, 255, 0, 128), 4)
# else
# # Negative DoT makes red screen
# $game_screen.start_flash(Color.new(255, 0, 0, 128), 4)
# end
# $game_temp.gameover = $game_party.all_dead?
# end
# }
# end
#end
***EDIT***
The original Class is included as a comment if you may be wondering what that is at the end.
I make it compatible with BABS & VX
#==============================================================================
# HoT DoT
# Author: Shdwlink1993
# Version: 1.04a
# Type: Poison Control
#
# Edited by KK20
# Edited by LiTTleDRAgo
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# HT Date 1.0b: 1/11/2009
# HT Date 1.01b: 1/12/2009
# HT Date 1.02: 2/19/2012
# HT Date 1.03: 3/20/2012
# HT Date 1.04: 4/08/2012
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# # This work is protected by the following license:
# #----------------------------------------------------------------------------
# #
# # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported
# # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ )
# #
# # You are free:
# #
# # to Share - to copy, distribute and transmit the work
# # to Remix - to adapt the work
# #
# # Under the following conditions:
# #
# # Attribution. You must attribute the work in the manner specified by the
# # author or licensor (but not in any way that suggests that they endorse you
# # or your use of the work).
# #
# # Noncommercial. You may not use this work for commercial purposes.
# #
# # Share alike. If you alter, transform, or build upon this work, you may
# # distribute the resulting work only under the same or similar license to
# # this one.
# #
# # - For any reuse or distribution, you must make clear to others the license
# # terms of this work. The best way to do this is with a link to this web
# # page.
# #
# # - Any of the above conditions can be waived if you get permission from the
# # copyright holder.
# #
# # - Nothing in this license impairs or restricts the author's moral rights.
# #
# #----------------------------------------------------------------------------
# #
# # Note that if you share this file, even after editing it, you must still
# # give proper credit to shdwlink1993.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Function =~
#
# This script is designed to allow you to expand what poison does to your
# character. Poison now is able to affect HP or SP, and take off a fraction or
# a set amount of HP/SP.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Version History =~
#
# Version 1.0b ---------------------------------------------------- [1/11/2009]
# Version 1.01b --------------------------------------------------- [1/12/2009]
# Version 1.02 ---------------------------------------------------- [2/19/2012]
# Version 1.03 ---------------------------------------------------- [3/20/2012]
# Version 1.04 ---------------------------------------------------- [4/08/2012]
#
# V 1.04 Changes:
# - DoT that heals will make the screen flash green instead of red
# - Damage values that were displayed in battle were inaccurate
# - Percentage based damage was written incorrectly
#
# V 1.03 Changes:
# - Percentage-based DoT healed when damage values were positive and visa-versa
# - Modified how variance was calculated (added explanation in config)
# - Organized script to be easier on the eyes and added comment lines
#
# V 1.02 Changes:
# - Negative damage values damaged instead of healed and visa-versa
# - Limit_Drain was bugged and has now been fixed
# - HP and SP damage was being calculated twice (thus actual damage/healing
# was twice the value the user configured)
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Customization =~
#
# Customization can be found right under where the Poison Database begins.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# ~= Compatability =~
#
# - Low probability of working with the SDK.
# - Will not work with other Poison-editing scripts.
# - Must be placed above Tons of Addons.
#
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
module SL93
def self.hotdot(id)
case id
#------------------------------------------------------------------------
# Poison Database Begins
#------------------------------------------------------------------------
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
#
# * STATE_NUMBER is the state you want to be affected by this.
# * TYPE refers to the thing sustaining damage.
# 1 = HP, 2 = SP. If the type is positive, the amount is a literal
# number (eg. You lose about 50 HP). If the type is negative, then
# the amount is a fraction of the maximum (eg. You lose about 50% of
# your HP).
# * DAMAGE refers to how much damage is healed/taken.
# A Positive amount hurts you and a negative amount heals you.
# * VARIANCE refers to how much the damage varies. Positive only.
# This depends in part on if TYPE was positive or negative.
#
# Example A: TYPE is positive. VARIANCE is 15.
# Damage/Heal amount can do up to 15 more or 15 less.
#
# Example B: TYPE is negative. VARIANCE is 15.
# Damage/Heal amount can do up to 15% more or 15% less.
#
# * LIMIT_DRAIN refers to if the poison can leave you with 0 HP/SP.
# If true, then it is limited, and stops at 1. If false, then it
# isn't.
# when STATE_NUMBER then return [TYPE, DAMAGE, VARIANCE, LIMIT_DRAIN]
#
#------------------------------------------------------------------------
when 3 then return [ -1, 10, 15, false] # Standard Poison
#------------------------------------------------------------------------
# Poison Database Ends
#------------------------------------------------------------------------
end
return false
end
end
#==============================================================================
# ** Game_Battler
#------------------------------------------------------------------------------
# This class deals with battlers. It's used as a superclass of the Game_Actor
# and Game_Enemy classes.
#==============================================================================
Klass = $BlizzABS ? Map_Battler : Game_Battler
class Klass
#--------------------------------------------------------------------------
# * Public Instance Variable
#--------------------------------------------------------------------------
attr_accessor :damage
#--------------------------------------------------------------------------
# * Constant
#--------------------------------------------------------------------------
VX = defined?(Window_ActorCommand)
#--------------------------------------------------------------------------
# * Determine [Slip Damage] States
#--------------------------------------------------------------------------
def slip_damage?
user = $BlizzABS ? self.battler : self
user.states.any? {|i| SL93.hotdot(i) || SL93.hotdot(i.id) }
end
#--------------------------------------------------------------------------
# * Application of Slip Damage Effects
#--------------------------------------------------------------------------
def slip_damage_effect
user = $BlizzABS ? self.battler : self
sp_method = VX ? :mp : :sp
maxsp_method = VX ? :maxmp : :maxsp
sp_damage = 0
user.damage = 0
# Get the HoT/DoT states applied to the character
ids = user.states.find_all {|i| SL93.hotdot(i) || SL93.hotdot(i.id)}
ids.collect! {|i| i.is_a?(Integer) ? i : i.id }
for i in ids.compact
# If the state damages/heals by a literal number
if SL93.hotdot(i)[0] > 0
damage = SL93.hotdot(i)[1]
# If the state damages/heals HP by a percent
elsif SL93.hotdot(i)[0] == -1
damage = user.maxhp * SL93.hotdot(i)[1] / 100
# If the state damages/heals SP by a percent
elsif SL93.hotdot(i)[0] == -2
damage = user.send(maxsp_method) * SL93.hotdot(i)[1] / 100
end
# If damage/heal amount is not zero and variance exists
if damage != 0 && SL93.hotdot(i)[2] > 0
# Variance based on literal numbers
amp = (damage.abs < SL93.hotdot(i)[2] ? damage.abs - 1 : SL93.hotdot(i)[2]) if SL93.hotdot(i)[0] > 0
# Variance based on percentages
amp = [damage.abs * SL93.hotdot(i)[2] / 100, 1].max if SL93.hotdot(i)[0] < 0
# Apply variance amounts to damage/heal amount
damage += rand(amp+1) + rand(amp+1) - amp
end
# If HP damage/heal
if SL93.hotdot(i)[0].abs == 1
hp = user.hp
# If limit_drain and actual HP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
user.hp = [hp - damage,1].max # Leave 1 HP
else
user.hp -= damage
end
# Add total damage to variable
user.damage += damage
# If SP damage/heal
elsif SL93.hotdot(i)[0].abs == 2
sp = user.send(sp_method)
# If limit_drain and actual SP damage being done (not healing)
if SL93.hotdot(i)[3] and damage > 0
user.sp = [sp - damage,1].max unless VX
user.mp = [sp - damage,1].max if VX# Leave 1 SP
else
user.sp -= damage unless VX
user.mp -= damage if VX
end
# Add total SP damage to variable
sp_damage += damage
end
end
# Modify @damage to be SP damage if no changes to HP were made
user.damage = sp_damage if user.damage == 0
end
end
#==============================================================================
# ** Game_Party
#------------------------------------------------------------------------------
# This class handles the party. It includes information on amount of gold
# and items. Refer to "$game_party" for the instance of this class.
#==============================================================================
class Game_Party
#--------------------------------------------------------------------------
# * Constant
#--------------------------------------------------------------------------
VX = defined?(Window_ActorCommand)
#--------------------------------------------------------------------------
# * Class Variable
#--------------------------------------------------------------------------
@@map_slip_damage = VX ? :on_player_walk : :check_map_slip_damage
#--------------------------------------------------------------------------
# * Processing Performed When Player Takes 1 Step
#--------------------------------------------------------------------------
define_method(:"#{@@map_slip_damage}") do |*args|
party = VX ? members : @actors
screen = VX ? $game_map.screen : $game_screen
party.each do |actor|
if actor.hp > 0 && actor.slip_damage?
actor.slip_damage_effect
if actor.damage <= 0
# Positive DoT makes green screen
screen.start_flash(Color.new(0, 255, 0, 128), 4)
else
# Negative DoT makes red screen
screen.start_flash(Color.new(255, 0, 0, 128), 4)
end
if $game_party.all_dead?
$game_temp.gameover = true if $game_temp.respond_to?(:gameover=)
$game_temp.next_scene = "gameover" if $game_temp.respond_to?(:next_scene=)
end
end
end
end
end
Hey Drago I plugged in your code replacing the script i had posted above.
there were no syntax errors, the script ran fine... but when the enemy received the venom state i couldn't see any damage being done.
I wanted to let you know about it. it may be an oversite or it may be one of my scripts are incompatible. im using the other version i posted. im not requesting that you fix it. i just wanted to let ya know.
These are current scripts that could be the culprerate if its script headbutt related
#Blizz ABS 1
#Blizz ABS 2
#Blizz ABS 3
#Landith: Blizz-ABS Party HUD++
#Winkio: Action Recharge Time
#LiTTleDRAgo: Smart Auto Targeting
#LiTTleDRAgo: DRG Inventory System
#HoT DoT: Shdwlink1993
#Now Loading Script: game_guy
#Fantasist: Threat System (skills configured but not yet moded for BABS)
# Item Art Color 1.21: LiTTleDRAgo
# Tax Script 2.0: Falcon
#DRG - Limited Shop 1.34: LiTTleDRAgo
#Multi-slot equipment script (1) 6.2.2: Guillaume777
#Multi-slot equipment script (2)
#Multi-slot equipment script (3)
#Multi-slot equipment script (4)
#Blacksmith Shop 2.0 (1): ForeverZer0
#Blacksmith Shop 2.0 (2)
#Blacksmith Shop 2.0 (3)
#Stat Distribution 2.2b: Blizzard
#Custom HotKey Mod to call 'Stat Distribution System'
***EDIT***
Also I'm looking to add the damage be visible.. so as each tick of the venom hits the damage is displayed as any other spell would show.
is there quick line i could add to make that possible? or is that a huge project? lol
***EDIT***
Actually now I'm back with another idea..
So it dawned on me... that if I have a boss fight...and im removing 10% per tick...any class that can apply a venom would be extremely powerful against bosses lol
so i was wondering if i could make a request. I want the game to have a Scale to it. so i want to be able to tweek it.
anywhoo here is the situation if anyone is interested in taking it on.
Currently:
Say the monster is hit for 30 damage after all calculations.
now say the boss has 10,000 HP. the spell lands for 30 damage after all calculations and applies the poison ...the applied state with 10% mean each tick is 1000 damage.. lol thats far too strong.
If i were to Exact damage the skill would never scale. meaning it would either be too powerful early on.. or too weak later on.
Solution:
Solution would be adding another option to make the poison be effected by a % of the damage.
once again after all calculations we land 30 damage on the enemy. the state is applied.
instead of removing 10% of the over all HP it would remove 10% of the over all damage i had done (30). so in really simple math terms.
Poison = Damage * .10
Also perhaps adding a scale with INT could be an option for scale. such as +INT * .30 or something to that effect.
I was looking into displaying the slip damage on screen and changing the poison myself..but ive realized i just don't have a clear enough understanding of the systems im using.
You can use my script (http://forum.chaos-project.com/index.php/topic,12232.0.html) to try and recreate that effect. An idea would be to make the skill apply two kinds of DoT states: one for normal monsters and the other for bosses. Make normal monsters fully resistant to the boss state and vice versa. I believe that script also has a "Display DoT Damage" feature.
When you use this outside of combat, it never seems to stop healing me. It just keeps on flashing green.
Quick but not perfect fix:
Modify the line to make it look like this
$game_screen.start_flash(Color.new(0, 255, 0, 128), 4) unless actor.hp == actor.maxhp
NoMethod occured. undefined method 'max_hp' for #<Game_Actor:0x6f47e50>
I remember double checking and I thought I put maxhp instead. Guess not, lol.