So here's the code. I don't know where to put something like when it's saying to put 'when 1 then return [[1, 2, 50], [3, 15, 10], [2, 4, 5]]'. where do i put one of that with my customized info in it?
:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
# Multi-Drop by Blizzard
# Version: 1.1b
# Type: Game Alteration
# Date: 13.11.2007
# Date v1.0b: 3.4.2008
# Date v1.1b: 5.6.2008
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
#
# Compatbility:
#
# Compatible with RTAB and Blizz-ABS 1.70 and higher. Will most probably
# cause problems with CBS-es that have the start_phase5 method modified.
#
#
# Explanation:
#
# This add-on allows you to make enemies that drop more than one item. The
# drops are independent, so if an enemy drops one item, he can drop another
# one as well. An enemy can even have a couple of drop of the same item.
#
#
# Instructions:
#
# Configure the drop database below and set up the compatibility
# configuration. The compatibility ocnfiguration is only needed if you are
# using RTAB. Blizz-ABS 1.70 and higher will be recognized automatically.
#
#
# Side note:
#
# This add-on could have been written in less than 100 lines of code, but
# full RTAB compatbility takes its piece of code.
#
#
# If you find any bugs, please report them here:
# http://forum.chaos-project.com
#:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
if TONS_OF_ADDONS::MULTI_DROP
#==============================================================================
# module BlizzCFG
#==============================================================================
module BlizzCFG
# set this to true if you are using RTAB
RTAB_USE = false
# set this to true if you are using Animated Battlers in RTAB
RTAB_ANIMA = false
# set this to true if you are using Battle Report v1.6 by Illustrationism
RTAB_REPORT = false
# limit of maximum items dropped, 0xFFFF is infinite
ITEM_LIMIT = 0xFFFF
def self.drop_configuration(id)
case id
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# START Drop Database
#
# Use the following template for configuration:
#
# when ID then return [[TYPE1, I_ID1, CH1], [TYPE2, I_ID2, CH2], ...]
#
# ID - enemy ID in the database
# TYPE - the drop type; 1 for items; 2 for weapons; 3 for armors
# I_ID - the drop item ID in the database
# CH - drop chance
#
# You can add as many drops as you want, separate them with commas. Keep in
# mind that if you set TYPE to 0, the drop is disabled and that you MUST NOT
# set I_ID to 0. If an enemy is not configured here, the default
# configuration from your database will be used, otherwise the default
# configuration from your database will be COMPLETELY OVERRIDEN.
#
# Example 1:
#
# when 1 then return [[1, 2, 50], [3, 15, 10], [2, 4, 5]]
#
# Monster with ID 1 can drop:
# 1 Item ID 2, chance 50%
# 1 Armor ID 15, chance 10%
# 1 Weapon ID 4, chance 5%
#
# Example 2:
#
# when 2 then return [[1, 1, 50], [1, 1, 40]]
#
# Monster with ID 2 can drop:
# 1 Item ID 1, chance 50%
# 1 Item ID 1, chance 40%
# Full chances of drops because of repeating items:
# nothing, chance 30%
# 1 Item ID 1, chance 50%
# 2 Items ID 1, chance 20%
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
when 1 then return [[1, 2, 50], [3, 15, 10], [2, 4, 5]]
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# END Drop Database
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
end
# return normal item drop if exists
if $data_enemies[id].item_id > 0
return [[1, $data_enemies[id].item_id, $data_enemies[id].treasure_prob]]
elsif $data_enemies[id].weapon_id > 0
return [[2, $data_enemies[id].weapon_id, $data_enemies[id].treasure_prob]]
elsif $data_enemies[id].armor_id > 0
return [[3, $data_enemies[id].armor_id, $data_enemies[id].treasure_prob]]
end
# no drop
return [[0, 0, 0]]
end
#----------------------------------------------------------------------------
# dropped_items
# enemy - a killed enemy
# This method returns an array of all dropped items.
#----------------------------------------------------------------------------
def self.dropped_items(enemy)
# initialize array
items = []
# get drops and start iteration through all drops
self.drop_configuration(enemy.id).each {|i|
# if got item
if rand(100) < i[2]
# add item, weapon or armor
case i[0]
when 1 then items.push($data_items[i[1]])
when 2 then items.push($data_weapons[i[1]])
when 3 then items.push($data_armors[i[1]])
end
end}
# result
return items
end
end
#==============================================================================
# Scene_Battle
#==============================================================================
class Scene_Battle
#----------------------------------------------------------------------------
# start_phase5
# This method was completely modified to support multi-drop.
#----------------------------------------------------------------------------
def start_phase5
# if RTAB and Animated Battlers in use
if BlizzCFG::RTAB_USE && BlizzCFG::RTAB_ANIMA
# don't end battle as long as an actor is moving around
$game_party.actors.each {|actor| return if @spriteset.battler(actor).moving}
# see if an actor remains alive
$victory = true if $game_party.actors.any? {|actor| !actor.dead?}
# see if an enemy remains alive
$defeat = true if $game_troop.enemies.reverse.any? {|enemy| !enemy.dead?}
end
@phase = 5
# set audio
$game_system.me_play($game_system.battle_end_me)
$game_system.bgm_play($game_temp.map_bgm)
# initialize variables
exp, gold, treasures = 0, 0, []
# if using RTAB
if BlizzCFG::RTAB_USE && !BlizzCFG::RTAB_REPORT
# dispose and setup special things from RTAB
@active_actor.blink = false if @active_actor != nil
$game_temp.battle_main_phase = true
@party_command_window.active = @party_command_window.visible =
@actor_command_window.active = @actor_command_window.visible = false
[@skill_window, @item_window].each {|win| win.dispose if win != nil}
@skill_window = @item_window = nil
@help_window.visible = false if @help_wait == 0
end
# iterate through all enemies
$game_troop.enemies.each {|enemy|
# if enemy isn't hidden
unless enemy.hidden
# get exp and gold
exp += enemy.exp
gold += enemy.gold
# get all dropped items
treasures += BlizzCFG.dropped_items(enemy)
end}
# limits treasures to a specific number
treasures = treasures[3..BlizzCFG::ITEM_LIMIT]
# if used battle RTAB battle report
if BlizzCFG::RTAB_REPORT
# used by battle report
@exp, @gold, @treasures = exp, gold, treasures
else
# iterate through all actor indices
$game_party.actors.each_index {|i|
actor = $game_party.actors[i]
# if actor can get EXP
unless actor.cant_get_exp?
# store last level
last_level = actor.level
actor.exp += exp
# if level increased after adding EXP
if actor.level > last_level
@status_window.level_up(i)
# if using RTAB
if BlizzCFG::RTAB_USE
# execute special RTAB commands
actor.damage[[actor, -1]] = 'Level up!'
actor.up_level = actor.level-last_level
end
end
end}
# add to party's gold
$game_party.gain_gold(gold)
# create result window
@result_window = Window_BattleResult.new(exp, gold, treasures)
end
# iterate through all treasures
treasures.each {|item|
# add gained treaures to party's inventory
case item
when RPG::Item then $game_party.gain_item(item.id, 1)
when RPG::Weapon then $game_party.gain_weapon(item.id, 1)
when RPG::Armor then $game_party.gain_armor(item.id, 1)
end}
@phase5_wait_count = 100
end
end
end