# * Icon Command Window script by mewsterus # * To install, just insert this in a descriptive code slot right above Main # * # * Icons for the command windows should be the same name as the command and PNG # * format. Every command in the game must have a graphic (including title, # * menu, and battle command windows). This applies only to fixed length # * vertical command windows. Place icons in the Graphics/Icons directory. #=============================================================================== # ¦ Window_Command #------------------------------------------------------------------------------- # Edited by mewsterus #=============================================================================== class Window_Command < Window_Selectable #----------------------------------------------------------------------------- # @ Draw choice #----------------------------------------------------------------------------- def draw_item(index, color) bitmap = RPG::Cache.icon(@commands[index] + ".png") opacity = color == normal_color ? 255 : 128 self.contents.blt(4, 32*index+4, bitmap, Rect.new(0, 0, 24, 24), opacity) self.contents.font.color = color rect = Rect.new(32, 32 * index, self.contents.width - 32, 32) self.contents.fill_rect(rect, Color.new(0, 0, 0, 0)) self.contents.draw_text(rect, @commands[index]) end end