#===========================================================================
# ** Battle Icons
#------------------------------------------------------------------------------
# Juan
# Version 3.0
# Date 8/21/08
# Date Last Updated 5/2/16
# Custom Battle Icon
#===========================================================================
#
#
# Compatibility:
# This script is 100% compatibly with Tons of add-ons and sdk 2.3 with editing.
# This script is compatible with Blizzard's easy party switcher using battle
# command switch on. This script will need to go below easy party switcher
# and another icon for battle switching will be needed. Anything that
# overides Window_PartyCommands def draw_item(index, color) will mean icons.
# and likely to need to be scripted to get the right position if new item is
# added to the pre fight commands. Not compatible with skill categories doesn't draw any icons at all...
#
#
#Features:
#
# -> This script lets you use battle icons for prefight commands
# and commands when fighting.
# -> Easy edit
#
#Version History
#
#Version 1.0
#-> This script was first made
# Version 2.0
# -> Improved Coding
# -> This scipt is now compatible with tons of add-ons by Blizzard
# Version 3.0
# -> Now icons are available for the menu and now show on fight and escape
# commands.
# -> now compatible with Skill Categories by Game Guy
# -> now compatible with Easy party Switcher by Blizzard
# particularly when using battle switch options.
#
#
# Instructions
# Change this line in scene battle 1 line 30
# @actor_command_window = Window_Command.new(160, [s1, s2, s3, s4])
# to @actor_command_window = Window_Battle_Command.new(160, [s1, s2, s3, s4])
# Then make icons called battle menu0 untill battle menu3 in the icons folder.
# Configure everything else below
#
#
#FAQ (Frequently Asked Questions):
#None so far
#
#
#Credits
# Juan
# Fantasist for suggesting I edit the pre fight command window to display icons too
#
#
#Author's Notes
#Any bugs
#Report them here:
#http://forum.chaos-project.com/index.php?topic=11.0
#or
#Email me
# Juanito119@yahoo.com
#Thats it
#enjoy
module Juan_Cfg
# How many commands you want icons for by default its 3
Battle_Icons_Amount = 3
# Name of the icon for the battle menu with number at the end starting from 0.
Battle_Icons_Name = "battle_menu"
# Do you want to enable support for the prebattle command?
Party_Window = true
# name of the party icons if party window is enabled with index from 0
Party_Icons_Name = "party_menu"
end
#===========================================================================
# Window_Battle_Command
#===========================================================================
class Window_Battle_Command < Window_Command
def draw_item(index, color)
self.contents.font.color = color
rect = Rect.new(4, 32 * index, self.contents.width - 8, 32)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
self.contents.font.color = color
# if command is greater than the amount specfiied in battle icons
# amount dont draw icon.
# this line is for compatabilty with Skill Categories by Game Guy from
# Chaos Project
if index > Juan_Cfg::Battle_Icons_Amount
rect = Rect.new(4, 32 * index, self.contents.width - 8, 32)
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
self.contents.draw_text(rect, @commands[index])
else
self.contents.blt(4, 4 + index*32, RPG::Cache.icon("#{Juan_Cfg::Battle_Icons_Name}#{index}"),
Rect.new(0, 0, 24, 24))
self.contents.draw_text(32, index*32, 148, 32, @commands[index])
end
end
end
if Juan_Cfg::Party_Window
#==============================================================================
# ** Window_PartyCommand
#------------------------------------------------------------------------------
# This window is used to select whether to fight or escape on the battle
# screen.
#==============================================================================
#$easy_party_switcher
class Window_PartyCommand < Window_Selectable
#--------------------------------------------------------------------------
# * Draw Item
# index : item number
# color : text character color
#--------------------------------------------------------------------------
def draw_item(index, color)
self.contents.font.color = color
if $easy_party_switcher && $game_system.battle_switch
self.contents.blt(84 + index * 160, 6,
RPG::Cache.icon("#{Juan_Cfg::Party_Icons_Name}#{index}"),
Rect.new(0, 0, 24, 24))
self.contents.draw_text(80 + index * 160 + 4, 0, 128 - 10, 32, @commands[index], 1)
else
self.contents.blt(163 + index * 160, 6,
RPG::Cache.icon("#{Juan_Cfg::Party_Icons_Name}#{index}"),
Rect.new(0, 0, 24, 24))
self.contents.draw_text(160 + index * 160, 0, 128, 32, @commands[index], 1)
end
end
end
end