Try v1.0:
#==============================================================================
# "Weapon/Armor HP/SP Plus" Add-on by Blizzard
# Version: 1.0
# Date: 18.8.2006
#
#
# Compatibility:
#
# 95% chance of compatibility with SDK. May cause slight incompatibility issues
# with CBS-es, but can be made compatible easily.
#
#
# Features:
#
# - uses static (i.e. 500 HP more) or dynamic (i.e. 30% HP more) increasements
# - easy to set up
# - does NOT change any rxdata files
# - this script comes UNDER SDK SCRIPTS if you use any
#
#
# Instructions:
#
# - Explanation:
#
# This script will add the option for Weapons/Armors to have HP/SP pluses while
# equipped just like the usual STR, DEX, INT etc. pluses.
#
# - Configuration
#
# 1) Activate
# Find in "Scene_Title" following lines:
#
# $data_weapons = load_data("Data/Weapons.rxdata")
# $data_armors = load_data("Data/Armors.rxdata")
#
# You will find these lines 2 times. Just ADD under them these lines:
#
# for weapon in $data_weapons
# weapon.init_hpsp_add_on unless weapon == nil
# end
# for armor in $data_armors
# armor.init_hpsp_add_on unless armor == nil
# end
#
# 2) Max HP and Max SP
# Change MAX_HP and MAX_SP to different values if you use another max HP and/or
# max SP limit than 9999.
#
# 3) Database
# Find the phrase saying "START" (CTRL+F) to find the database parts. Use the
# following template to configure your database:
#
# when ID then return [EXPR, VAL]
#
# ID - Weapon/Armor ID in the normal database
# EXPR - set to false if you want "static" increasement or true if you want
# "dynamic" increasement
# VAL - if you use static increasement, set this value to any integer you want
# (i.e. 100, -500, 831 etc.) to increase the HP/SP, otherwise set it to
# any decimal value of the final HP/SP (i.e. 1.2 = 20% more, 2.3 = 130%
# more, 0.7 = 30% less)
#
# VAL can be a negative integer (static increasement) OR a decimal number
# greater than 0 (dynamic increasement).
#
#
# Side Note:
#
# It took more to write the instructions than to write and test script itself.
#
#
# If you find any bugs, please report them here:
# http://www.chaosproject.co.nr
# or send me an e-mail:
# boris_blizzard@yahoo.de
#
#==============================================================================
MAX_HP = 9999 # change if needed, 9999 is standard
MAX_SP = 9999 # change if needed, 9999 is standard
#==============================================================================
# Game_Battler
#==============================================================================
class Game_Battler
alias maxsp_hpsp_add_on_later maxsp
def maxsp
val = [MAX_SP, maxsp_hpsp_add_on_later].min
@sp = val if @sp > val
return val
end
end
#==============================================================================
# Game_Actor
#==============================================================================
class Game_Actor < Game_Battler
alias maxhp_hpsp_add_on_later maxhp
def maxhp
val = [MAX_HP, maxhp_hpsp_add_on_later].min
@hp = val if @hp > val
return val
end
alias base_maxhp_hpsp_add_on_later base_maxhp
def base_maxhp
plus = 0
multi = 1.0
weapon = $data_weapons[@weapon_id]
armor = []
armor.push($data_armors[@armor1_id])
armor.push($data_armors[@armor2_id])
armor.push($data_armors[@armor3_id])
armor.push($data_armors[@armor4_id])
if weapon != nil
multi *= weapon.hp_plus[1] if weapon.hp_plus[0]
plus += weapon.hp_plus[1] if not weapon.hp_plus[0]
end
for i in 0...4
if armor[i] != nil
multi *= armor[i].hp_plus[1] if armor[i].hp_plus[0]
plus += armor[i].hp_plus[1] if not armor[i].hp_plus[0]
end
end
return (multi * (plus + base_maxhp_hpsp_add_on_later)).to_i
end
alias base_maxsp_hpsp_add_on_later base_maxsp
def base_maxsp
plus = 0
multi = 1.0
weapon = $data_weapons[@weapon_id]
armor = []
armor.push($data_armors[@armor1_id])
armor.push($data_armors[@armor2_id])
armor.push($data_armors[@armor3_id])
armor.push($data_armors[@armor4_id])
if weapon != nil
multi *= weapon.sp_plus[1] if weapon.sp_plus[0]
plus += weapon.sp_plus[1] if not weapon.sp_plus[0]
end
for i in 0...4
if armor[i] != nil
multi *= armor[i].sp_plus[1] if armor[i].sp_plus[0]
plus += armor[i].sp_plus[1] if not armor[i].sp_plus[0]
end
end
return (multi * (plus + base_maxsp_hpsp_add_on_later)).to_i
end
end
#==============================================================================
# module RPG
# Weapon
#==============================================================================
class RPG::Weapon
attr_reader :hp_plus
attr_reader :sp_plus
def init_hpsp_add_on
@hp_plus = quota_hp
@sp_plus = quota_sp
end
def quota_hp
case @id
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# START Weapon HP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
when 1 then return [false, 350]
when 5 then return [true, 1.2]
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# END Weapon HP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
else
return [false, 0]
end
end
def quota_sp
case @id
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# START Weapon SP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
when 25 then return [false, 500]
when 29 then return [true, 1.5]
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# END Weapon SP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
else
return [false, 0]
end
end
end
#==============================================================================
# module RPG
# Armor
#==============================================================================
class RPG::Armor
attr_reader :hp_plus
attr_reader :sp_plus
def init_hpsp_add_on
@hp_plus = quota_hp
@sp_plus = quota_sp
end
def quota_hp
case @id
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# START Armor HP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
when 1 then return [true, 1.1]
when 5 then return [true, 0.5]
when 13 then return [false, 90]
when 17 then return [false, -450]
when 9 then return [true, 1.3]
when 21 then return [true, 1.3]
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# END Armor HP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
else
return [false, 0]
end
end
def quota_sp
case @id
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# START Armor SP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
when 9 then return [true, 1.3]
when 21 then return [true, 1.3]
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# END Armor SP plus Configuration
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
else
return [false, 0]
end
end
end