Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Equipment Weight + Multi-Slot Merge

Pretty much what I want here is a merge of both Trickster's Equipment Weight Script and Trickster's Multi Equip V3.0.

If you need the bare scripts:
Code:
=begin
#==============================================================================
# ●● Multi-Equip + Multi-Attack
#------------------------------------------------------------------------------
# Trickster (tricksterguy@hotmail.com)
# Version 3.0
# Date 4/14/07
# Goto rmxp.org for updates/support/bug reports
#==============================================================================
=end
#--------------------------------------------------------------------------
# ● Begin SDK Log
#--------------------------------------------------------------------------
SDK.log('Multi-Equip', 'Trickster', 3.0, '4/14/07')
#--------------------------------------------------------------------------
# Begin SDK Requirement Check
#--------------------------------------------------------------------------
SDK.check_requirements(2.0, [1, 2])
#--------------------------------------------------------------------------
# ● Begin SDK Enabled Check
#--------------------------------------------------------------------------
if SDK.enabled?('Multi-Equip')
  
module Multi_Equip
  #--------------------------------------------------------------------------
  # * How Many Weapon Slots Needed (Maximum)
  #--------------------------------------------------------------------------
  Weapon_Slots = 2
  #--------------------------------------------------------------------------
  # * How Many Armor Slots Needed (Maximum)
  #--------------------------------------------------------------------------
  Armor_Slots = 6
  #--------------------------------------------------------------------------
  # * Equip Names For Slots for Actors
  #     syntax - actor_id => [names] or %w( names )
  #--------------------------------------------------------------------------
  Actor_Names = {
  1 => %w( Sword Sword Shield Helm Armor/Plate Ring Amulet ),
  2 => %w( Spear Shield Helm Armor/Plate Ring ),
  7 => ['Mace','Hat','Robe','Ring'],
  8 => ['Rod','Hat','Robe','Ring']
  }
  #--------------------------------------------------------------------------
  # * Equip Names For Slots Classes
  #     syntax - class_id => [names] or %w( names )
  #--------------------------------------------------------------------------
  Class_Names = {
  1 => %w( Sword Sword Shield Helm Armor/Plate Ring Amulet ),
  2 => %w( Spear Shield Helm Armor/Plate Ring ),
  7 => ['Mace','Hat','Robe','Ring'],
  8 => ['Rod','Hat','Robe','Ring']
  }
  #--------------------------------------------------------------------------
  # * Equip Types For Slots
  #     syntax - actor_id = [types] 
  #     note - w = weapon an = armor kind n
  #--------------------------------------------------------------------------
  Actor_Types = {
  }
  #--------------------------------------------------------------------------
  # * Equip Types For Slots
  #     syntax - class_id = [types] or %( types )
  #     note - w = weapon an = armor kind n
  #--------------------------------------------------------------------------
  Class_Types = {
  1 => %w( w w a1 a2 a3 a4 a5 ),
  2 => %w( w a1 a2 a3 a4 ),
  7 => ['w', 'a2', 'a3', 'a4'],
  8 => ['w', 'a2', 'a3', 'a4']
  }
  #--------------------------------------------------------------------------
  # * Initial Equipment
  #     syntax - actor_id => {slot id => equip id}
  #--------------------------------------------------------------------------
  Init_Equip = {
  1 => {0=>1, 2=>1, 3=>5, 4=>13},
  2 => {0=>5, 1=>1, 2=>5, 3=>17},
  7 => {0=>25, 1=>9, 2=>21},
  8 => {0=>29, 1=>9, 2=>21}
  }
  #--------------------------------------------------------------------------
  # * Battle Test Equipment
  #     syntax - actor_id => {slot id => equip id}
  #--------------------------------------------------------------------------
  BT_Equip = {
  1 => {0=>4, 1=>2, 2=>1, 3=>5, 4=>13},
  2 => {0=>5, 1=>1, 2=>5, 3=>17},
  7 => {0=>25, 1=>9, 2=>21},
  8 => {0=>29, 1=>9, 2=>21}
  }
  #--------------------------------------------------------------------------
  # * Fixed Equipment
  #     syntax - actor_id => {slot_id => bool}
  #--------------------------------------------------------------------------
  Equip_Fix = {
  }
  #--------------------------------------------------------------------------
  # * Armor_Types
  #   syntax - armor_id = (kind - 1)
  #--------------------------------------------------------------------------
  Armor_Types = {33 => 4
  }
  #--------------------------------------------------------------------------
  # * Setup All Default Values (Don't Touch)
  #--------------------------------------------------------------------------
  words = SDK::Scene_Commands::DataSystem.words
  #--------------------------------------------------------------------------
  # * Set Class Types Default to Corresponding words for each slot
  #--------------------------------------------------------------------------
  Class_Names.default = words.weapon, words.armor1, words.armor2, words.armor3, 
  words.armor4
  #--------------------------------------------------------------------------
  # * Set Class Names Default to The Normal Five Slots
  #--------------------------------------------------------------------------
  Class_Types.default = %( w a1 a2 a3 a4 )
#--------------------------------------------------------------------------
#  End SDK Enabled Check
#--------------------------------------------------------------------------
end
end
Code:
#--------------------------------------------------------------------------
# ● Begin SDK Enabled Check
#--------------------------------------------------------------------------
if SDK.enabled?('Multi-Equip')
  
class Scene_Equip
  #--------------------------------------------------------------------------
  # * Main Processing : Window Initialization
  #--------------------------------------------------------------------------
  def main_window
    super
    # Make windows
    @help_window = Window_Help.new
    @left_window = Window_EquipLeft.new(@actor)
    @right_window = Window_EquipRight.new(@actor)
    @item_window = Window_EquipItem.new(@actor, 0)
    # Associate help window
    @right_window.help_window = @help_window
    @item_window.help_window = @help_window
    # Set cursor position
    @right_window.index = @equip_index
    # Refresh Data
    refresh
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    # Get currently equipped item
    item1 = @right_window.item
    # Get Slot
    slot = @actor.slot_types[@right_window.index]
    # Convert to Kind
    slot = slot == 'w' ? 0 : slot[1...slot.size].to_i
    # Set Equip Type
    @item_window.equip_type = slot
    # If right window is active erase parameters for after equipment change
    @left_window.clear_parameters if @right_window.active
    # Get currently equipped item
    item1 = @right_window.item
    # Return if item window isn't active
    return if not @item_window.active
    # Get currently selected item
    item2 = @item_window.item
    # Change Equipment
    last_hp = @actor.hp
    last_sp = @actor.sp
    @actor.equip(@right_window.index, item2 == nil ? 0 : item2.id)
    # Get parameters for after equipment change
    new_str = @actor.str
    new_dex = @actor.dex
    new_agi = @actor.agi
    new_int = @actor.int
    new_atk = @actor.atk
    new_pdef = @actor.pdef
    new_mdef = @actor.mdef
    new_eva = @actor.eva
    # Return equipment
    @actor.equip(@right_window.index, item1 == nil ? 0 : item1.id)
    @actor.hp = last_hp
    @actor.sp = last_sp
    # Draw in left window
    @left_window.set_new_parameters(new_atk, new_pdef, new_mdef, new_str, 
    new_dex, new_agi, new_int, new_eva)
  end
end

class Window_EquipLeft
  #--------------------------------------------------------------------------
  # * Object Initialization
  #     actor : actor
  #--------------------------------------------------------------------------
  def initialize(actor)
    super(0, 64, 320, 192)
    self.contents = Bitmap.new(width - 32, height - 32)
    @actor = actor
    @new_stats = []
    # Set Font Size of Window
    self.contents.font.size = 18
    refresh
  end
  #--------------------------------------------------------------------------
  # * Draw Parameter
  #     actor : actor
  #     x     : draw spot x-coordinate
  #     y     : draw spot y-coordinate
  #     type  : parameter type (0-7)
  #--------------------------------------------------------------------------
  def draw_actor_parameter(actor, x, y, type)
    # Get New Value
    new_value = @new_stats[type]
    # Branch By Type
    case type
    when 0
      parameter_name = $data_system.words.atk
      old_value = actor.atk
    when 1
      parameter_name = $data_system.words.pdef
      old_value = actor.pdef
    when 2
      parameter_name = $data_system.words.mdef
      old_value = actor.mdef
    when 3
      parameter_name = $data_system.words.str
      old_value = actor.str
    when 4
      parameter_name = $data_system.words.dex
      old_value = actor.dex
    when 5
      parameter_name = $data_system.words.agi
      old_value = actor.agi
    when 6
      parameter_name = $data_system.words.int
      old_value = actor.int
    when 7
      parameter_name = 'EVA'
      old_value = actor.eva
    end
    new_value = old_value if new_value == nil
    # Setup Color
    self.contents.font.color = system_color
    # Draw Parameter Name
    self.contents.draw_text(x, y, 64, 32, parameter_name)
    color = (new_value > old_value ? up_color : 
    new_value == old_value ? normal_color : down_color)
    self.contents.font.color = color
    self.contents.draw_text(x + 64, y, 64, 32, new_value.to_s, 2)
    self.contents.font.color = normal_color
  end
  #--------------------------------------------------------------------------
  # * Down Color
  #--------------------------------------------------------------------------
  def down_color
    return Color.new(160, 32, 32)
  end
  #--------------------------------------------------------------------------
  # * Up Color
  #--------------------------------------------------------------------------
  def up_color
    return Color.new(255, 215, 0)
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    # Clear Bitmap
    self.contents.clear
    # Draw Name
    draw_actor_name(@actor, 4, 0)
    # Draw Level
    draw_actor_level(@actor, 148, 0)
    # Draw Stats
    draw_actor_parameter(@actor, 4, 32, 3)
    draw_actor_parameter(@actor, 148, 32, 4)
    draw_actor_parameter(@actor, 4, 64, 5)
    draw_actor_parameter(@actor, 148, 64, 6)
    draw_actor_parameter(@actor, 4, 96, 0)
    draw_actor_parameter(@actor, 148, 96, 1)
    draw_actor_parameter(@actor, 4, 128, 2)
    draw_actor_parameter(@actor, 148, 128, 7)
  end
  #--------------------------------------------------------------------------
  # * Set parameters after changing equipment
  #--------------------------------------------------------------------------
  def set_new_parameters(*stats)
    return if @new_stats == stats
    @new_stats = stats
    refresh
  end
  #--------------------------------------------------------------------------
  # * Clear Parameters
  #--------------------------------------------------------------------------
  def clear_parameters
    return if @new_stats.empty?
    @new_stats.clear
    refresh
  end
end

class Window_EquipRight
  #--------------------------------------------------------------------------
  # * Object Initialization
  #     actor : actor
  #--------------------------------------------------------------------------
  def initialize(actor)
    super(320, 64, 320, 192)
    # Set Actor
    @actor = actor
    # Get Height of Contents
    contents_height = @actor.slot_types.size * 32
    # Create Bitmap
    self.contents = Bitmap.new(width - 32, contents_height)
    # Set Font Size of Window
    self.contents.font.size = 18
    # Refresh
    refresh
    # Set Index
    self.index = 0
  end
  #--------------------------------------------------------------------------
  # * Draw Item Name
  #     item : item
  #     x    : draw spot x-coordinate
  #     y    : draw spot y-coordinate
  #--------------------------------------------------------------------------
  def draw_item_name(item, x, y)
    # If Item is nil
    if item == nil
      # System Color
      self.contents.font.color = system_color
      # Draw No Equip
      self.contents.draw_text(x + 28, y, 212, 32, 'No Equip')
      # Return
      return
    end
    # Get Icon Pic
    bitmap = RPG::Cache.icon(item.icon_name)
    # Draw Icon
    self.contents.blt(x, y + 4, bitmap, Rect.new(0, 0, 24, 24))
    # Normal Color
    self.contents.font.color = normal_color
    # Draw Item Name
    self.contents.draw_text(x + 28, y, 212, 32, item.name)
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    self.contents.clear
    @data = []
    # Setup Equipment Indexes
    weapon_index = 0
    armor_index = 1
    # Get Boolean value for if weapon slot
    slots = @actor.slot_types.collect {|slot| slot == 'w'}
    # Get All Equipment
    slots.each do |slot|
      # If weapon slot
      if slot
        # Increment Weapon Index
        weapon_index += 1
        # If First
        if weapon_index == 1
          # Push First Weapon ID
          @data << $data_weapons[@actor.weapon_id]
        # Else
        else
          # Push (weapon index)th weapon id
          weapon_id = @actor.method("weapon#{weapon_index}_id").call
          # Push Weapon
          @data << $data_weapons[weapon_id]
        end
      # If Armor Slot
      else
        # Push (armor index)th armor id
        armor_id = @actor.method("armor#{armor_index}_id").call
        # Push Armor
        @data << $data_armors[armor_id]
        # Increment Armor index
        armor_index += 1
      end
    end
    # Setup Item Max
    @item_max = @data.size
    # Set Color
    self.contents.font.color = system_color
    # Draw Slot Names
    @actor.slot_names.each_with_index do |name, index|
      self.contents.draw_text(4, 32 * index, 112, 32, name)
    end
    # Draw Item Names
    @data.each_with_index {|item, index| draw_item_name(item, 116, 32 * index)}
  end
end

class Window_EquipItem
  #--------------------------------------------------------------------------
  # * Object Initailization
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_equipitem_initialize, :initialize
  def initialize(*args)
    # Setup Data
    @data = []
    # The Usual
    trick_multiequip_equipitem_initialize(*args)
  end
  #--------------------------------------------------------------------------
  # * Set Equip Type
  #--------------------------------------------------------------------------
  def equip_type=(equip_type)
    # Return if smae
    return if @equip_type == equip_type
    # Set new equip type
    @equip_type = equip_type
    # refresh
    refresh
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    # Clear Data
    @data.clear
    # Add equippable weapons
    if @equip_type == 0
      weapon_set = $data_classes[@actor.class_id].weapon_set
      (1...$data_weapons.size).each do |id|
        if $game_party.weapon_number(id) > 0 and weapon_set.include?(id)
          @data << $data_weapons[id]
        end
      end
    end
    # Add equippable armor
    if @equip_type != 0
      armor_set = $data_classes[@actor.class_id].armor_set
      (1...$data_armors.size).each do |id|
        if $game_party.armor_number(id) > 0 and armor_set.include?(id)
          @data << $data_armors[id] if $data_armors[id].kind == @equip_type - 1
        end
      end
    end
    # Add Blank Item
    @data << nil
    # Make a bit map and draw all items
    @item_max = @data.size
    # If Item count is not 0
    if @item_max > 0
      # If Contents is defined and same height
      if self.contents != nil and row_max * 32 == self.contents.height
        # Clear Contents
        self.contents.clear
      else
        # If Contents is Defined Dispose Contents
        self.contents.dispose unless self.contents.nil?
        # Create Bitmap
        self.contents = Bitmap.new(width - 32, row_max * 32)
        # Set Font Size of Window
        self.contents.font.size = 18
      end
      # Draw Items
      (@item_max-1).times {|i| draw_item(i)}
    else
      # If Contents is Defined Dispose Contents
      self.contents.dispose unless self.contents.nil?
      # Create Bitmap
      self.contents = Bitmap.new(width - 32, height - 32)
    end
  end
end
#--------------------------------------------------------------------------
#  End SDK Enabled Check
#--------------------------------------------------------------------------
end
Code:
#--------------------------------------------------------------------------
# ● Begin SDK Enabled Check
#--------------------------------------------------------------------------
if SDK.enabled?('Multi-Equip')
  
class Window_Base
  #--------------------------------------------------------------------------
  # * Draw Actor Equipment
  #--------------------------------------------------------------------------
  def draw_actor_equipment(actor, x, y)
    # Setup Equipment Array
    equipment = []
    # Setup Equipment Indexes
    weapon_index = 0
    armor_index = 1
    # Get Boolean value for if weapon slot
    slots = @actor.slot_types.collect {|slot| slot == 'w'}
    # Get All Equipment
    slots.each do |slot|
      # If weapon slot
      if slot
        # Increment Weapon Index
        weapon_index += 1
        # If First
        if weapon_index == 1
          # Push First Weapon ID
          equipment << $data_weapons[@actor.weapon_id]
        # Else
        else
          # Push (weapon index)th weapon id
          weapon_id = @actor.method("weapon#{weapon_index}_id").call
          # Push Weapon
          equipment << $data_weapons[weapon_id]
        end
      # If Armor Slot
      else
        # Push (armor index)th armor id
        armor_id = @actor.method("armor#{armor_index}_id").call
        # Push Armor
        equipment << $data_armors[armor_id]
        # Increment Armor index
        armor_index += 1
      end
    end
    # Set Color
    self.contents.font.color = system_color
    # Draw Slot Names
    @actor.slot_names.each_with_index do |name, index|
      self.contents.draw_text(x + 4, y + 32 * index, 112, 32, name)
    end
    # Draw Item Names
    equipment.each_with_index do |item, index| 
      draw_item_name(item, x + 116, y +32 * index)
    end
  end
end

class Window_Status
  #--------------------------------------------------------------------------
  # * Object Initialization
  #     actor : actor
  #--------------------------------------------------------------------------
  def initialize(actor)
    super(0, 0, 640, 480)
    self.contents = Bitmap.new(width - 32, height - 32)
    @actor = actor
    refresh
  end
  #--------------------------------------------------------------------------
  # * Draw Item Name
  #     item : item
  #     x    : draw spot x-coordinate
  #     y    : draw spot y-coordinate
  #--------------------------------------------------------------------------
  def draw_item_name(item, x, y)
    # If Item is nil
    if item == nil
      # System Color
      self.contents.font.color = system_color
      # Draw No Equip
      self.contents.draw_text(x + 28, y, 212, 32, 'No Equip')
      # Return
      return
    end
    # Get Icon Pic
    bitmap = RPG::Cache.icon(item.icon_name)
    # Draw Icon
    self.contents.blt(x, y + 4, bitmap, Rect.new(0, 0, 24, 24))
    # Normal Color
    self.contents.font.color = normal_color
    # Draw Item Name
    self.contents.draw_text(x + 28, y, 212, 32, item.name)
  end
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    self.contents.clear
    draw_actor_graphic(@actor, 40, 112)
    draw_actor_name(@actor, 4, 0)
    draw_actor_class(@actor, 4 + 144, 0)
    draw_actor_level(@actor, 96, 32)
    draw_actor_state(@actor, 96, 64)
    draw_actor_hp(@actor, 96, 112, 172)
    draw_actor_sp(@actor, 96, 144, 172)
    draw_actor_parameter(@actor, 96, 192, 0)
    draw_actor_parameter(@actor, 96, 224, 1)
    draw_actor_parameter(@actor, 96, 256, 2)
    draw_actor_parameter(@actor, 96, 304, 3)
    draw_actor_parameter(@actor, 96, 336, 4)
    draw_actor_parameter(@actor, 96, 368, 5)
    draw_actor_parameter(@actor, 96, 400, 6)
    self.contents.font.color = system_color
    self.contents.draw_text(320, 48, 80, 32, 'EXP')
    self.contents.draw_text(320, 80, 80, 32, 'NEXT')
    self.contents.font.color = normal_color
    self.contents.draw_text(320 + 80, 48, 84, 32, @actor.exp_s, 2)
    self.contents.draw_text(320 + 80, 80, 84, 32, @actor.next_rest_exp_s, 2)
    self.contents.font.color = system_color
    self.contents.draw_text(320, 160, 96, 32, 'equipment')
    draw_actor_equipment(@actor, 320, 208)
  end
  #def dummy
  #  draw_actor_equipment(@actor, 320, 112)
  #end
end
#--------------------------------------------------------------------------
#  End SDK Enabled Check
#--------------------------------------------------------------------------
end
Code:
#--------------------------------------------------------------------------
# ● Begin SDK Enabled Check
#--------------------------------------------------------------------------
if SDK.enabled?('Multi-Equip')

class Scene_Title
  #--------------------------------------------------------------------------
  # * Main Database
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_main_database, :main_database
  def main_database
    # The Usual
    trick_multiequip_main_database
    # Run Through Defined Armor Types
    Multi_Equip::Armor_Types.each do |armor_id, kind|
      # Set Kind for armor
      $data_armors[armor_id].kind = kind
    end
  end
end

class Game_Party
  #--------------------------------------------------------------------------
  # * Battle Test Party Setup
  #--------------------------------------------------------------------------
  def setup_battle_test_members
    # Setup Actors
    @actors = []
    # Run Through Battle Testers
    $data_system.test_battlers.each do |battler|
      # Get Game_Actor Object
      actor = $game_actors[battler.actor_id]
      # Set Level
      actor.level = battler.level
      # Recover
      actor.recover_all
      # Setup Battle Test Status
      actor.setup_battle_test
      # Push onto Actors
      @actors << actor
    end
    # Setup Items
    @items = {}
    # Run Through Each Item
    $data_items.each do |item|
      # Skip if item is nil or item name is empty
      next if item == nil or item.name.empty?
      # If Items occasion is in battle or always get 99 of them
      @items[item.id] = 99 if [0,1].include?(item.occasion)
    end
  end
end

class Game_Actor
  #--------------------------------------------------------------------------
  # * Public Instance Variables
  #--------------------------------------------------------------------------
  (1...Multi_Equip::Weapon_Slots).each {|i| eval("attr_reader :weapon#{i+1}_id")}
  Multi_Equip::Armor_Slots.times {|i| eval("attr_reader :armor#{i+1}_id")}
  attr_accessor :weapon_index
  #--------------------------------------------------------------------------
  # * Setup
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_setup, :setup
  def setup(actor_id)
    # The Usual
    trick_multiequip_actor_setup(actor_id)
    # Initialize Weapon and Armor Index
    weapon_index = 0
    armor_index = 1
    # Run Through The Number of Slots Defined
    slot_types.size.times do |index|
      # Set Default to 0
      equip_id = 0
      # If has actor id as one of the keys
      if Multi_Equip::Init_Equip.has_key?(actor_id)
        # Get Equip id (also turn nil to 0 default)
        equip_id = Multi_Equip::Init_Equip[actor_id][index].to_i
      end
      # Get Slot Information
      slot = slot_types[index]
      # If A Weapon Slot
      if slot == 'w'
        # Increment Weapon Index
        weapon_index += 1
        # If the First Index
        if weapon_index == 1
          # Set Weapon Id to Equip Id
          @weapon_id = equip_id
        else
          # Set Weapon(N) Id to Equip Id
          eval("@weapon#{weapon_index}_id = equip_id")
        end
      # If A Armor Slot
      elsif slot[0,1] == 'a'
        # Set Armor(N) Id to Equip Id
        eval("@armor#{armor_index}_id = equip_id")
        # Increment Armor Index
        armor_index += 1
      end
    end
    # Get All Armors
    armors = self.armor_ids
    # Restrict to Armors not Accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get Corresponding RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Set Auto States
    new_armors.each {|armor| update_auto_state(nil, armor)}
    # Setup Weapon Index
    @weapon_index = 0
  end
  #--------------------------------------------------------------------------
  # * Setup Battle Test
  #--------------------------------------------------------------------------
  def setup_battle_test
    # Initialize Weapon and Armor Index
    weapon_index = 0
    armor_index = 1
    # Clear All Equip Ids
    update_auto_state($data_armors[@armor1_id], nil)
    update_auto_state($data_armors[@armor2_id], nil)
    update_auto_state($data_armors[@armor3_id], nil)
    update_auto_state($data_armors[@armor4_id], nil)
    # Set All to Zero
    @weapon_id, @armor1_id, @armor2_id, @armor3_id, @armor4_id = 0,0,0,0,0
    # Run Through The Number of Slots Defined
    slot_types.size.times do |index|
      # Set Default to 0
      equip_id = 0
      # If has actor id as one of the keys
      if Multi_Equip::BT_Equip.has_key?(actor_id)
        # Get Equip id (also turn nil to 0 default)
        equip_id = Multi_Equip::BT_Equip[@actor_id][index].to_i
      end
      # Get Slot Information
      slot = slot_types[index]
      # If A Weapon Slot
      if slot == 'w'
        # Increment Weapon Index
        weapon_index += 1
        # If the First Index
        if weapon_index == 1
          # Set Weapon Id to Equip Id
          @weapon_id = equip_id
        else
          # Set Weapon(N) Id to Equip Id
          eval("@weapon#{weapon_index}_id = equip_id")
        end
      # If A Armor Slot
      elsif slot[0,1] == 'a'
        # Set Armor(N) Id to Equip Id
        eval("@armor#{armor_index}_id = equip_id")
        # Increment Armor Index
        armor_index += 1
      end
    end
    # Get All Armors
    armors = self.armor_ids
    # Restrict to Armors not Accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get Corresponding RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Set Auto States
    new_armors.each {|armor| update_auto_state(nil, armor)}
    # Setup Weapon Index
    @weapon_index = 0
  end
  #--------------------------------------------------------------------------
  # * Slot Types
  #--------------------------------------------------------------------------
  def slot_types
    # If actor id for Actor Types has been set up
    if Multi_Equip::Actor_Types.has_key?(@actor_id)
      # Return that value
      return Multi_Equip::Actor_Types[@actor_id]
    else
      # Return Class Types for Class ID
      return Multi_Equip::Class_Types[@class_id]
    end
  end
  #--------------------------------------------------------------------------
  # * Slot Names
  #--------------------------------------------------------------------------
  def slot_names
    # If actor id for Actor Names has been set up
    if Multi_Equip::Actor_Names.has_key?(@actor_id)
      # Return that value
      return Multi_Equip::Actor_Names[@actor_id]
    else
      # Return Class Names for Class ID
      return Multi_Equip::Class_Names[@class_id]
    end
  end
  #--------------------------------------------------------------------------
  # * Determine Fixed Equipment
  #     slot_id : slot_type
  #--------------------------------------------------------------------------
  def equip_fix?(slot_id)
    if Multi_Equip::Equip_Fix.has_key?(@actor_id)
      equip_fix = Multi_Equip::Equip_Fix[@actor_id]
      return equip_fix.has_key?(slot_id) ? equip_fix[slot_id] : false
    else
      return false
    end
  end
  #--------------------------------------------------------------------------
  # * Change Equipment
  #     alot_id : type of equipment
  #     id    : weapon or armor ID (If 0, remove equipment)
  #--------------------------------------------------------------------------
  def equip(slot_id, id)
    # Initialize Index
    index = 0
    # Get Slots
    slots = slot_types.collect {|slot| slot == 'w' ? 'w' : 'a'}
    # Get Slot Type
    slot_type = slots[slot_id]
    # Get Weapon/Armor index
    (0..slot_id).each {|slot_index| index += 1 if slots[slot_index] == slot_type}
    # If a Weapon Slot
    if slot_type == 'w'
      # If Id is Zero (Unequip) or if party has the weapon
      if id == 0 or $game_party.weapon_number(id) > 0
        # Get Corresponding Instance Variable
        weapon_index = index == 1 ? '@weapon_id' : "@weapon#{index}_id"
        # Switch Weapons Get Currently Equipped Weapon
        $game_party.gain_weapon(eval(weapon_index), 1)
        # Set Instance Variable to New Weapon Id
        eval("#{weapon_index} = id")
        # Lose New Equipped Weapon
        $game_party.lose_weapon(id, 1)
      end
    # Elsif A Armor Slot
    elsif slot_type == 'a'
      # If Id is Zero (Unequip) or if party has the armor
      if id == 0 or $game_party.armor_number(id) > 0
        # Get Both Armors
        armor1 = $data_armors[eval("@armor#{index}_id")]
        armor2 = $data_armors[id]
        # Update Auto State
        update_auto_state(armor1, armor2)
        # Gain An Currently Equipped Armor
        $game_party.gain_armor(eval("@armor#{index}_id"), 1)
        # Set Instance Variable to New Armor ID
        eval("@armor#{index}_id = id")
        # Lose New Equipped Weapon
        $game_party.lose_armor(id, 1)
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Unequip all
  #--------------------------------------------------------------------------
  def unequip_all
    # Run Through The Number of Slots Defined and Equip at Slot Index
    slot_types.size.times {|index| equip(index, 0)}
  end
  #--------------------------------------------------------------------------
  # * Get Element Revision Value
  #     element_id : element ID
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_element_rate, :element_rate
  def element_rate(element_id)
    # Get Result
    result = trick_multiequip_actor_element_rate(element_id)
    # Get All Armors
    armors = self.armor_ids
    # Restrict to Armors not Accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get Corresponding RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # If this element is protected by armor, then it's reduced by half
    new_armors.each {|armors| 
    result /= 2 if armor.guard_element_set.include?(element_id)}
    # End Method
    return result
  end
  #--------------------------------------------------------------------------
  # * Determine State Guard
  #     state_id : state ID
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_state_guard?, :state_guard?
  def state_guard?(state_id)
    # Get Flag
    flag = trick_multiequip_actor_state_guard?(state_id)
    # Get All Armors
    armors = self.armor_ids
    # Restrict to Armors not Accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get Corresponding RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # If this element is protected by armor, then it's reduced by half
    new_armors.each {|armors| 
    return true if armor.guard_state_set.include?(state_id)}
    # Return Flag
    return flag
  end
  #--------------------------------------------------------------------------
  # * Get Normal Attack Element
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_element_set, :element_set
  def element_set
    # If not in battle or in battle and phase is not 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # The Usual
      return trick_multiequip_actor_element_set
    end
    # Else Get From Current Weapon Id
    weapon = $data_weapons[self.current_weapon_id]
    # Return Element Set
    return weapon != nil ? weapon.element_set : []
  end
  #--------------------------------------------------------------------------
  # * Get Normal Attack State Change (+)
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_plus_state_set, :plus_state_set
  def plus_state_set
    # If not in Scene_Battle or in Scene_Battle and phase is not 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # The Usual
      return trick_multiequip_actor_plus_state_set
    end
    # Else Get From Current Weapon Id
    weapon = $data_weapons[self.current_weapon_id]
    # Return Plus State Set
    return weapon != nil ? weapon.plus_state_set : []
  end
  #--------------------------------------------------------------------------
  # * Get Normal Attack State Change (-)
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_minus_state_set, :minus_state_set
  def minus_state_set
    # If not in Scene_Battle or in Scene_Battle and phase is not 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # The Usual
      return trick_multiequip_actor_minus_state_set
    end
    # Else Get From Current Weapon Id
    weapon = $data_weapons[self.current_weapon_id]
    # Return Minus State Set
    return weapon != nil ? weapon.minus_state_set : []
  end
  #--------------------------------------------------------------------------
  # * Change Class ID
  #     class_id : new class ID
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_class_id=, :class_id=
  def class_id=(class_id)
    # The Usual
    self.trick_multiequip_actor_class_id = class_id
    # If Valid Class Remove All
    self.unequip_all if $data_classes[class_id] != nil
  end
  #--------------------------------------------------------------------------
  # * Get Basic Strength
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_str, :base_str
  def base_str
    # Get Strength
    n = trick_multiequip_actor_base_str
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add agility if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.str_plus : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get All Weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add agility if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.str_plus : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.str_plus : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.str_plus : 0
    end
    # Return Strength
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Dexterity
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_dex, :base_dex
  def base_dex
    # Get Dexerity
    n = trick_multiequip_actor_base_dex
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add agility if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.dex_plus : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get All Weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add agility if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.dex_plus : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.dex_plus : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.dex_plus : 0
    end
    # Return Dexerity
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Agility
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_agi, :base_agi
  def base_agi
    # Get Agility
    n = trick_multiequip_actor_base_agi
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add agility if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.agi_plus : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get All Weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add agility if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.agi_plus : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.agi_plus : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.agi_plus : 0
    end
    # Return Agility
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Intelligence
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_int, :base_int
  def base_int
    # Get Intelligence
    n = trick_multiequip_actor_base_int
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add intelligence if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.int_plus : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get All Weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add intelligence if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.int_plus : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.int_plus : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.int_plus : 0
    end
    # Return Intelligence
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Attack Power
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_atk, :base_atk
  def base_atk
    # Get Attack Power
    n = trick_multiequip_actor_base_atk
    # Get All Armors
    armors = self.armor_ids
    # Get All Armors
    new_armors = armors
    # Get RPG::Armor Objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # If A Method was created for Attack Power in RPG::Armor
    if new_armors[0].respond_to?(:atk)
      # Then go on and add those too
      new_armors.each {|armor| n += armor != nil ? armor.atk : 0}
    end
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get all weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon and RPG::Armor objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add attack power if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.atk : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.atk : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.atk : 0
    end
    # Return Attack Power
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Physical Defense
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_pdef, :base_pdef
  def base_pdef
    # Get Physical Defense
    n = trick_multiequip_actor_base_pdef
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add physical defense if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.pdef : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get All Weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add physical defense if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.pdef : 0}
    else
      # Get First Weapon 
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.pdef : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.pdef : 0
    end
    # Return Physical Defense
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Magic Defense
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_mdef, :base_mdef
  def base_mdef
    # Get Magic Defense
    n = trick_multiequip_actor_base_mdef
    # Get all armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Weapon and RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add magic defense if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.mdef : 0}
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get all weapons
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons.size > 1 ? weapons[1...weapons.size] : []
      # Get RPG::Weapon and RPG::Armor objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Add magic defense if nil add nothing
      new_weapons.each {|weapon| n += weapon != nil ? weapon.mdef : 0}
    else
      # Get First Weapon 
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.mdef : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.mdef : 0
    end
    # Return Magic Defense
    return n
  end
  #--------------------------------------------------------------------------
  # * Get Basic Evasion Correction
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_actor_base_eva, :base_eva
  def base_eva
    # Get Evasion
    n = trick_multiequip_actor_base_eva
    # Get all weapons and armors
    armors = self.armor_ids
    # Restrict to those not accounted for
    new_armors = armors.size > 4 ? armors[4...armors.size] : []
    # Get RPG::Armor objects
    new_armors.collect! {|armor_id| $data_armors[armor_id]}
    # Add evasion if nil add nothing
    new_armors.each {|armor| n += armor != nil ? armor.eva : 0}
    # Return if RPG::Weapon doesn't respond to eva
    return n if not $data_weapons[1].respond_to?(:eva)
    # If not in battle or in battle and not in phase 4
    if !$game_temp.in_battle or ($game_temp.in_battle and $scene.phase != 4)
      # Get all weapons and armors
      weapons = self.weapon_ids
      # Restrict to those not accounted for
      new_weapons = weapons
      # Get RPG::Weapon and RPG::Armor objects
      new_weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # If method created for evasion for weapons
      new_weapons.each {|weapon| n += weapon != nil ? weapon.eva : 0}
    else
      # Get First Weapon
      weapon = $data_weapons[@weapon_id]
      # Get Current Attacking Weapon
      weapon1 = $data_weapons[self.current_weapon_id]
      # Subtract Already Calculated Weapon Id
      n -= weapon != nil ? weapon.eva : 0
      # Add Current Weapon Id
      n += weapon1 != nil ? weapon1.eva : 0
    end
    # Return Evasion
    return n
  end
  #--------------------------------------------------------------------------
  # * Current Attacking Weapon Id
  #--------------------------------------------------------------------------
  def current_weapon_id
    return self.weapon_ids[@weapon_index]
  end
end
#--------------------------------------------------------------------------
#  End SDK Enabled Check
#--------------------------------------------------------------------------
end
Code:
#--------------------------------------------------------------------------
# ● Begin SDK Enabled Check
#--------------------------------------------------------------------------
if SDK.enabled?('Multi-Equip')
  
class Scene_Battle
  #--------------------------------------------------------------------------
  # * Public Instance Variables
  #--------------------------------------------------------------------------
  attr_reader :animation2_ids
  attr_reader :phase
  #--------------------------------------------------------------------------
  # * Main Processing
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_battler_main_variable, :main_variable
  def main_variable
    # Initialize Animation 2 ids
    @animation2_ids = []
    # The Usual
    trick_multiequip_battler_main_variable
  end
  #--------------------------------------------------------------------------
  # * Frame Update (main phase step 1 : action preparation)
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_battler_update_phase4_step1, :update_phase4_step1
  def update_phase4_step1
    # The Usual
    trick_multiequip_battler_update_phase4_step1
    # Set All Animation 2 Ids
    @animation2_ids.clear
  end
  #--------------------------------------------------------------------------
  # * Make Basic Action Results
  #--------------------------------------------------------------------------
  alias_method(:trick_multiequip_battler_make_basic_action_result,
    :make_basic_action_result)
  def make_basic_action_result
    # The Usual
    trick_multiequip_battler_make_basic_action_result
    # return if action is not an attack
    return if not @active_battler.current_action.is_a_attack?
    # if Active Battler is a Game_Actor
    if @active_battler.is_a?(Game_Actor)
      # Get all weapons whose Id is not zero
      weapons = @active_battler.weapon_ids
      # Delete 0 if included
      weapons.delete(0) if weapons.include?(0)
      if weapons.size == 1
        # Get Weapon ID
        weapon_id = weapons[0]
        # Get Weapon
        weapon = $data_weapons[weapon_id]
        # Set Animation ID and Animation 2 ID
        @animation1_id = weapon.animation1_id
        @animation2_id = weapon.animation2_id
      end
      # If only one weapon return
      return if weapons.size <= 1
      # Get Corresponding RPG::Armor Objects
      weapons.collect! {|weapon_id| $data_weapons[weapon_id]}
      # Get all of their attacking animation ids
      animation_ids = []
      weapons.each {|weapon| animation_ids << weapon.animation2_id}
      # Set Attacking Animations to this
      @animation2_ids = animation_ids
    end
  end
  #--------------------------------------------------------------------------
  # * Update Phase4 Step4
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_battler_update_phase4_step4, :update_phase4_step4
  def update_phase4_step4
    # The Usual
    trick_multiequip_battler_update_phase4_step4
    # Return if no Animation 2 ids
    return if @animation2_ids.empty?
    # Get Animation 2 id in question
    animation_id = @animation2_ids.shift
    # Animation for target
    @target_battlers.each do |target|
      # Get Damage
      damage = target.weapon_damage.shift
      # Set Animation ID
      target.animation_id = animation_id
      # Set Animation Hit
      target.animation_hit = damage != "Miss"
    end
  end
  #--------------------------------------------------------------------------
  # * Update Phase4 Step5
  #--------------------------------------------------------------------------
  alias_method :trick_multiequip_battler_update_phase4_step5, :update_phase4_step5
  def update_phase4_step5
    # The Usual
    trick_multiequip_battler_update_phase4_step5
    # Return if no Amination 2 ids
    return if @animation2_ids.empty?
    # Go Back to Step Four (Still more animations to play)
    @phase4_step = 4
  end
end
#--------------------------------------------------------------------------
#  End SDK Enabled Check
#--------------------------------------------------------------------------
end



Code:
#=============================================================================
# â–  Equipment Weights
#=============================================================================
# Trickster (tricksterguy@hotmail.com) 
# Version 1.6
# 2.19.07
# Posted on rmxp.org find updates there
#=============================================================================
# Whats New
#   Cleaned Up Code
#
#
# Instructions
#   Format for Curve Constants
#   [min, mid, max, minL, midL, maxL, early, late, steady, curve1, curve2, int]
#
# Where:
#   min    - the minimum value of the stat
#   mid    - the middle value at midL
#   max    - the maximum value of the stat
#   minL   - the minimum level
#   midL   - the middle level (stat will be mid here)
#   maxL   - the maximum level
#   early  - the early influence
#   late   - the late influence
#   steady - the steady influence
#   curve1 - the early->late influence
#   curve2 - the late->early influence
#   int    - if true returns integers
#
# Notes:
#
#   The Default Values for the Curve Options
#   minL = 1, midL = 50, maxL = 99, influence options = 0, int = true
#  
#   You must set at least one of the curve options to a number other than 0
#  
#   Using the Steady Curve Option will throw off the middle value option, since
#   the steady curve grows steadily and its middle value will always occur on the
#   middle level, that is, (maxL - minL) / 2.
#=============================================================================
#--------------------------------------------------------------------------
# * Begin SDK Log
#--------------------------------------------------------------------------
SDK.log("Equipment Weights", "Trickster", 1.6, "2.19.07")

#--------------------------------------------------------------------------
# * Begin SDK Enable Test
#--------------------------------------------------------------------------
if SDK.state("Equipment Weights") == true 

module Weights_Setup
  #--------------------------------------------------------------------------
  # * Weight Names
  #--------------------------------------------------------------------------
  Weight_Names = 'kg', 'g', 'mg'
  #--------------------------------------------------------------------------
  # * Conversion Table
  #   - kg <- g <- mg
  #--------------------------------------------------------------------------
  Conversion = 0.001, 0.001
  #--------------------------------------------------------------------------
  # * Leading Name
  #--------------------------------------------------------------------------
  Leading_Name = 'kg'
  #--------------------------------------------------------------------------
  # * Digits (Number of Digits after decimal point) > more precise
  #--------------------------------------------------------------------------
  Digits = 2
  #--------------------------------------------------------------------------
  # * Tolerance smaller == more precise
  #--------------------------------------------------------------------------
  Tolerance = 0.001
  #--------------------------------------------------------------------------
  # * Weapon Weights
  #   - syntax: weapon_id => weight
  #   - use a string if not leading name ex '##name'
  #--------------------------------------------------------------------------
  Weapon_Weights = {
  1 => 50, 5 => 5, 25 => 3, 29 => 1
  }
  #--------------------------------------------------------------------------
  # * Weapon Weights Default
  #--------------------------------------------------------------------------
  Weapon_Weights.default = 10
  #--------------------------------------------------------------------------
  # * Armor Weights
  #   - syntax: armor_id => weight
  #   - use a string if not leading name
  #--------------------------------------------------------------------------
  Armor_Weights = {
  1 => 10, 5 => 5, 9 => '500g', 13 => 15, 17 => 7, 21 => '750g', 31 => '10g'
  }
  #--------------------------------------------------------------------------
  # * Armor Weights Default
  #--------------------------------------------------------------------------
  Armor_Weights.default = 20
  #--------------------------------------------------------------------------
  # * Weight Curve 
  #   - Syntax actor_id => [stat curve]
  #   - Note: Express min, mid, and max in terms of the leading weight
  #   - Note: add a false at the end of the array to allow for floats (decimals)
  #   - Note: See instructions
  #--------------------------------------------------------------------------
  Weight_Curve_Actor = {
  1 => [50, 60, 40, 1, 50, 100, 0, 0, 1],
  2 => [30, 30, 30, 1, 50, 100, 0, 0, 1],
  7 => [15, 15, 15, 1, 50, 100, 0, 0, 1],
  8 => [10, 10, 10, 1, 50, 100, 0, 0, 1]
  }
  #--------------------------------------------------------------------------
  # * Weight Curve Default
  #--------------------------------------------------------------------------
  Weight_Curve_Actor.default = [25, 25, 25, 1, 20, 100, 0, 0, 1]
  #--------------------------------------------------------------------------
  # * Penalty Setup
  #   - 0: Can't Equip 1: Can Equip (Stats Down)
  #--------------------------------------------------------------------------
  Penalty_Setup = 1
  #--------------------------------------------------------------------------
  # * Stat Decrease Type
  #   - 0: Constant Multiplier
  #   - 1: Dependent Overweight (total / over) (Only Penalties affected)
  #   - 2: All Dependent on Overweight (All Stats are affected)
  #--------------------------------------------------------------------------
  Stat_Decrease = 2
  #--------------------------------------------------------------------------
  # * Stat Penalties
  #   - syntax: stat_name => rate
  #   - maxhp, maxsp, str, dex, agi, int, atk, pdef, mdef, eva, hit, speed.
  #--------------------------------------------------------------------------
  Stat_Penalties = {'agi' => 0.5, 'eva' => 0.1
  }
  #--------------------------------------------------------------------------
  # * Stat Penalties Default
  #--------------------------------------------------------------------------
  Stat_Penalties.default = 1
  #--------------------------------------------------------------------------
  # * Nox Penalty (Actor Can not move in battle)
  #   - syntax actor_id => bool (true to can't false can
  #--------------------------------------------------------------------------
  Nox_Penalty = { 1 => true
  }
  #--------------------------------------------------------------------------
  # * Nox Penalties Default
  #--------------------------------------------------------------------------
  Nox_Penalty.default = false
  #--------------------------------------------------------------------------
  # * Walking Speed Effect
  #   0: First Actor 1: All Party
  #--------------------------------------------------------------------------
  Walking_Effect = 1
  #--------------------------------------------------------------------------
  # * Module Function Conversion
  #--------------------------------------------------------------------------
  module_function
  def conversion(string)
    # Return If A Number (In Leading Units)
    return string if string.is_a?(Numeric)
    # Get Number
    number = string.sub(/\D+/, '').to_f
    # Get Units
    name = string.sub(/\d+/, '')
    # Return if Leading Units
    return number if Leading_Name == name
    # Get index
    index = Weight_Names.index(name)
    # Get Leading Index
    lead = Weight_Names.index(Leading_Name)
    # Get Start and Finish
    start, finish = [index, lead].sort
    # Get Exponent
    exp = (index - lead).sign * 1.0
    # Move to Lead
    (start...finish).each do |i|
      # Convert to next unit
      number *= Conversion[i] ** exp
    end
    # Return number
    return number
  end
  #--------------------------------------------------------------------------
  # * Module Function Format
  #--------------------------------------------------------------------------
  def format(number)
    # Get Digits
    leading = (number * 10 ** Digits.to_f).to_i / 10 ** Digits.to_f
    # To Integer if decimal is less than tolerance
    leading = leading.to_i if (leading.to_i - leading).abs <= Tolerance
    # Return String if option 0 of weight display
    return "#{leading} #{Leading_Name}"
  end
end

#--------------------------------------------------------------------------
# * End SDK Enable Test
#--------------------------------------------------------------------------
end
Code:
#--------------------------------------------------------------------------
# * Begin SDK Enable Test
#--------------------------------------------------------------------------
if SDK.state("Equipment Weights") == true 
  
module RPG
class Weapon
  #--------------------------------------------------------------------------
  # * Weight
  #--------------------------------------------------------------------------
  def weight
    # Get Increase Carry Weight
    carry = Weights_Setup::Weapon_Weights[id]
    # Convert to Float
    weight = Weights_Setup.conversion(carry)
    # Return Weight
    return weight
  end
  #--------------------------------------------------------------------------
  # * Weight String
  #--------------------------------------------------------------------------
  def weight_s
    return Weights_Setup.format(weight)
  end
end

class Armor
  #--------------------------------------------------------------------------
  # * Weight
  #--------------------------------------------------------------------------
  def weight
    # Get Increase Carry Weight
    carry = Weights_Setup::Armor_Weights[id]
    # Convert to Float
    weight = Weights_Setup.conversion(carry)
    # Return Weight
    return weight
  end
  #--------------------------------------------------------------------------
  # * Weight String
  #--------------------------------------------------------------------------
  def weight_s
    return Weights_Setup.format(weight)
  end
end
end

class Game_Actor
  #--------------------------------------------------------------------------
  # * Setup
  #------------------------------------------------------------
 
It doesn't work with that script either.
Neither of them work but I prefer G777's script to be the one merged. But if you find Trickster's to be easier to work with, go ahead by all means.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top