Munkis' DOOM-Style main menu
Version: 1.4
Author: munkis
Release Date: 01/07/2011
Exclusive Script at RPG RPG Revolution
Introduction
Basically this changes the main menu to a simpler menu similar to the one in DOOM.
Features
This script has a logo window at the top of the screen, a transparent command window, and a HUD at the bottom that shows a gold window, a map name window that turns into a scrolling marquee if the map name is longer than the window, and a play time window. I also have several add-ons for this script that will add different things to the HUD.
Required Images
You can either use these in your project, or as a placeholder until you get someone to make what you want.
Images




Script
Munkis' DOOM-Style Main Menu
CODE
#------------------------------------------------------------------------------
# * Munkis' DOOM-Style Main Menu V 1.4
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Basically this changes the main menu to a simpler menu similar to the one
# in DOOM I. I was actually working on this when I made the Simple Menu for
# Deadbox.
# * OVERWRITES Scene_Menu!
# * V 1.0: Initial release
# * V 1.1: Pictures used in Menu_Title can now be up to 544 pixels wide (can
# be moved around to fit properly in the window from the config module), but
# still have to be 124 pixels tall. This is unlikely to change.
# * V 1.11: Minor improvements to HUD appearance.
# * V 1.12: Minor changes made for an as-yet-to-be-released script I have in
# the works (05/09/2010) *UPDATE* Munkis' Animated Picture Menuback has been
# released.
# * V 1.2: Added a picture backed HUD option. Also thinned the code out a bit.
# * V 1.3: Map name now turns into a scrolling marquee if it is longer than the
# window.
# * V 1.4: Will now bypass the actor select screen if there is only one member
# in the party.
#------------------------------------------------------------------------------
#[module]
module MNK_Picture_Menu
#Gold Window, Map Name Window, Play Time Window
ICONS = [138, 153, 188]
#Name of picture used in Menu_Title, x co-ordinate of picture
MENU_TITLE_PICTURE = ["Menu_Title",-30]
#Appearence of small windows, large background window, colors of small
#windows, HUD picture back, HUD Picture name.
MENU_BAR_PROPERTIES = [true,false,Color.new(0,0,0,128),Color.new(255,0,0,160),true,"HUD_Pictureback"]
MENU_COMMANDS = ["Item","Skill","Equipment","Status","Save","Game End","Return to Game"]
#The scroll speed of the map name in frames
MAP_NAME_SCROLL = 30
end
#[/module]
#------------------------------------------------------------------------------
# * This changes the currency symbol in the gold window.
#------------------------------------------------------------------------------
class Window_Base
def draw_currency_value(value, x, y, width)
self.contents.font.color = normal_color
self.contents.draw_text(x, y, width, WLH, value, 2)
draw_icon(MNK_Picture_Menu::ICONS[0], x, y)
end
end
#------------------------------------------------------------------------------
# * This draws the Play Time window.
#------------------------------------------------------------------------------
class Play_Time_Window < Window_Base
def initialize (x, y)
super (x, y, 160, 32 + WLH)
self.opacity = 0
refresh
end
#----------------------------------------------------------------------------
# * Refresh
#----------------------------------------------------------------------------
def refresh
self.contents.clear
x, tw = 0, contents.width
if MNK_Picture_Menu::ICONS[2] >= 0
draw_icon (MNK_Picture_Menu::ICONS[2], x, 0)
x += 24
tw -= 24
end
@total_sec = Graphics.frame_count / Graphics.frame_rate
hour = @total_sec / 60 / 60
min = @total_sec / 60 % 60
sec = @total_sec % 60
text = sprintf("%02d:%02d:%02d", hour, min, sec)
self.contents.font.color = normal_color
self.contents.draw_text(x, 0, tw, WLH, text, 2)
end
#----------------------------------------------------------------------------
# * Frame Update
#----------------------------------------------------------------------------
def update
super
if Graphics.frame_count / Graphics.frame_rate != @total_sec
refresh
end
end
end
#------------------------------------------------------------------------------
# * This draws the Map Name window.
#------------------------------------------------------------------------------
class Map_Icon_Window < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x, y, 260, height)
x, tw = 0, contents.width
if MNK_Picture_Menu::ICONS[1] >= 0
draw_icon (MNK_Picture_Menu::ICONS[1], x, 0)
x += 24
tw -= 24
end
self.opacity = 0
end
end
class Map_Name_Window < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+30, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@reset_scroll = false
self.opacity = 0
refresh
end
def refresh
self.contents.clear
create_contents
@text_size = self.contents.text_size($game_map.map_name).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, $game_map.map_name, 0)
end
def update
super
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, $game_map.map_name, 0)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
class Game_Map
def map_name
return load_data ("Data/MapInfos.rvdata")[$game_map.map_id].name
end
end
#------------------------------------------------------------------------------
# * This draws the Menu Title picture.
#------------------------------------------------------------------------------
class Menu_Title < Window_Base
def initialize
super(0,0,544,155)
self.z = 1
self.opacity = 0
bitmap = Cache.picture(MNK_Picture_Menu::MENU_TITLE_PICTURE[0])
rect = Rect.new(MNK_Picture_Menu::MENU_TITLE_PICTURE[1], 0, 544, 124)
self.contents.blt(x, y, bitmap, rect)
bitmap.dispose
end
end
#------------------------------------------------------------------------------
# * This draws the Menu Bar pictures as well as the large background window.
#------------------------------------------------------------------------------
class Menu_Bar_1 < Window_Base
def initialize
super(0,344,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_2 < Window_Base
def initialize
super(132,344,300,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,237,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_3 < Window_Base
def initialize
super(374,344,170,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,136,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,364,544,52)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Menu_Bar_Pic < Window_Base
def initialize
super(-16,0,580,440)
self.z = 0
self.opacity = 0
self.visible = MNK_Picture_Menu::MENU_BAR_PROPERTIES[4]
bitmap = Cache.picture(MNK_Picture_Menu::MENU_BAR_PROPERTIES[5])
rect = Rect.new(-16, -300, 580, 440)
self.contents.blt(x, y, bitmap, rect)
bitmap.dispose
end
end
#------------------------------------------------------------------------------
# * This actually draws the menu and puts all the other windows where they
# need to be.
#------------------------------------------------------------------------------
class Scene_Menu < Scene_Base
#----------------------------------------------------------------------------
# * Object Initialization
# menu_index : command cursor's initial position
#----------------------------------------------------------------------------
def initialize(menu_index = 0)
@menu_index = menu_index
end
#----------------------------------------------------------------------------
# * Start processing
#----------------------------------------------------------------------------
def start
super
create_menu_background
create_command_window
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
@status_window = Window_MenuStatus.new(80, 0)
@status_window.visible = false
end
#----------------------------------------------------------------------------
# * Termination Processing
#----------------------------------------------------------------------------
def terminate
super
dispose_menu_background
@command_window.dispose
@gold_window.dispose
@status_window.dispose
@time_window.dispose
@titlewindow.dispose
@icon_window.dispose
@map_name_window.dispose
@menubar1.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubar2.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubar3.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubarback.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == false
@menubarpic.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[4] == false
end
#----------------------------------------------------------------------------
# * Frame Update
#----------------------------------------------------------------------------
def update
super
update_menu_background
@command_window.update
@gold_window.update
@status_window.update
@time_window.update
@map_name_window.update
if @command_window.active
update_command_selection
elsif @status_window.active
update_actor_selection
end
end
#----------------------------------------------------------------------------
# * Create Command Window
#----------------------------------------------------------------------------
def create_command_window
s1 = MNK_Picture_Menu::MENU_COMMANDS[0]
s2 = MNK_Picture_Menu::MENU_COMMANDS[1]
s3 = MNK_Picture_Menu::MENU_COMMANDS[2]
s4 = MNK_Picture_Menu::MENU_COMMANDS[3]
s5 = MNK_Picture_Menu::MENU_COMMANDS[4]
s6 = MNK_Picture_Menu::MENU_COMMANDS[5]
s7 = MNK_Picture_Menu::MENU_COMMANDS[6]
s8 = MNK_Picture_Menu::MENU_COMMANDS[7]
if $game_system.save_disabled # If save is forbidden
@command_window = Window_Command.new(180,[s1, s2, s3, s4, s6, s7]) # Remove command from window
else
@command_window = Window_Command.new(180,[s1, s2, s3, s4, s5, s6, s7])
end
@command_window.x = 187
@command_window.y = 125
@command_window.height = 235
@command_window.opacity = 0
@command_window.index = @menu_index
if $game_party.members.size == 0 # If number of party members is 0
@command_window.draw_item(0, false) # Disable item
@command_window.draw_item(1, false) # Disable skill
@command_window.draw_item(2, false) # Disable equipment
@command_window.draw_item(3, false) # Disable status
end
end
#----------------------------------------------------------------------------
# * Update Command Selection
#----------------------------------------------------------------------------
def update_command_selection
if Input.trigger?(Input::B)
Sound.play_cancel
$scene = Scene_Map.new
elsif Input.trigger?(Input::C)
if $game_party.members.size == 0 and @command_window.index < 4
Sound.play_buzzer
return
end
Sound.play_decision
if $game_party.members.size < 2
case @command_window.index
when 0 # Item
$scene = Scene_Item.new
when 1 # skill
$scene = Scene_Skill.new(0)
when 2 # equipment
$scene = Scene_Equip.new(0)
when 3 # status
$scene = Scene_Status.new(0)
when 4
if $game_system.save_disabled
$scene = Scene_End.new
else
$scene = Scene_File.new(true, false, false)
end
when 5
if $game_system.save_disabled
$scene = Scene_Map.new
else
$scene = Scene_End.new
end
when 6
$scene = Scene_Map.new
end
else
case @command_window.index
when 0 # Item
$scene = Scene_Item.new
when 1,2,3 # Skill, equipment, status
@status_window.visible = true
start_actor_selection
when 4
if $game_system.save_disabled
$scene = Scene_End.new
else
$scene = Scene_File.new(true, false, false)
end
when 5
if $game_system.save_disabled
$scene = Scene_Map.new
else
$scene = Scene_End.new
end
when 6
$scene = Scene_Map.new
end
end
end
end
#----------------------------------------------------------------------------
# * Start Actor Selection
#----------------------------------------------------------------------------
def start_actor_selection
@command_window.active = false
@status_window.active = true
if $game_party.last_actor_index < @status_window.item_max
@status_window.index = $game_party.last_actor_index
else
@status_window.index = 0
end
end
#----------------------------------------------------------------------------
# * End Actor Selection
#----------------------------------------------------------------------------
def end_actor_selection
@command_window.active = true
@status_window.active = false
@status_window.index = -1
@status_window.visible = false
end
#----------------------------------------------------------------------------
# * Update Actor Selection
#----------------------------------------------------------------------------
def update_actor_selection
if Input.trigger?(Input::B)
Sound.play_cancel
end_actor_selection
elsif Input.trigger?(Input::C)
$game_party.last_actor_index = @status_window.index
Sound.play_decision
case @command_window.index
when 1 # skill
$scene = Scene_Skill.new(@status_window.index)
when 2 # equipment
$scene = Scene_Equip.new(@status_window.index)
when 3 # status
$scene = Scene_Status.new(@status_window.index)
end
end
end
end
# * Munkis' DOOM-Style Main Menu V 1.4
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Basically this changes the main menu to a simpler menu similar to the one
# in DOOM I. I was actually working on this when I made the Simple Menu for
# Deadbox.
# * OVERWRITES Scene_Menu!
# * V 1.0: Initial release
# * V 1.1: Pictures used in Menu_Title can now be up to 544 pixels wide (can
# be moved around to fit properly in the window from the config module), but
# still have to be 124 pixels tall. This is unlikely to change.
# * V 1.11: Minor improvements to HUD appearance.
# * V 1.12: Minor changes made for an as-yet-to-be-released script I have in
# the works (05/09/2010) *UPDATE* Munkis' Animated Picture Menuback has been
# released.
# * V 1.2: Added a picture backed HUD option. Also thinned the code out a bit.
# * V 1.3: Map name now turns into a scrolling marquee if it is longer than the
# window.
# * V 1.4: Will now bypass the actor select screen if there is only one member
# in the party.
#------------------------------------------------------------------------------
#[module]
module MNK_Picture_Menu
#Gold Window, Map Name Window, Play Time Window
ICONS = [138, 153, 188]
#Name of picture used in Menu_Title, x co-ordinate of picture
MENU_TITLE_PICTURE = ["Menu_Title",-30]
#Appearence of small windows, large background window, colors of small
#windows, HUD picture back, HUD Picture name.
MENU_BAR_PROPERTIES = [true,false,Color.new(0,0,0,128),Color.new(255,0,0,160),true,"HUD_Pictureback"]
MENU_COMMANDS = ["Item","Skill","Equipment","Status","Save","Game End","Return to Game"]
#The scroll speed of the map name in frames
MAP_NAME_SCROLL = 30
end
#[/module]
#------------------------------------------------------------------------------
# * This changes the currency symbol in the gold window.
#------------------------------------------------------------------------------
class Window_Base
def draw_currency_value(value, x, y, width)
self.contents.font.color = normal_color
self.contents.draw_text(x, y, width, WLH, value, 2)
draw_icon(MNK_Picture_Menu::ICONS[0], x, y)
end
end
#------------------------------------------------------------------------------
# * This draws the Play Time window.
#------------------------------------------------------------------------------
class Play_Time_Window < Window_Base
def initialize (x, y)
super (x, y, 160, 32 + WLH)
self.opacity = 0
refresh
end
#----------------------------------------------------------------------------
# * Refresh
#----------------------------------------------------------------------------
def refresh
self.contents.clear
x, tw = 0, contents.width
if MNK_Picture_Menu::ICONS[2] >= 0
draw_icon (MNK_Picture_Menu::ICONS[2], x, 0)
x += 24
tw -= 24
end
@total_sec = Graphics.frame_count / Graphics.frame_rate
hour = @total_sec / 60 / 60
min = @total_sec / 60 % 60
sec = @total_sec % 60
text = sprintf("%02d:%02d:%02d", hour, min, sec)
self.contents.font.color = normal_color
self.contents.draw_text(x, 0, tw, WLH, text, 2)
end
#----------------------------------------------------------------------------
# * Frame Update
#----------------------------------------------------------------------------
def update
super
if Graphics.frame_count / Graphics.frame_rate != @total_sec
refresh
end
end
end
#------------------------------------------------------------------------------
# * This draws the Map Name window.
#------------------------------------------------------------------------------
class Map_Icon_Window < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x, y, 260, height)
x, tw = 0, contents.width
if MNK_Picture_Menu::ICONS[1] >= 0
draw_icon (MNK_Picture_Menu::ICONS[1], x, 0)
x += 24
tw -= 24
end
self.opacity = 0
end
end
class Map_Name_Window < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+30, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@reset_scroll = false
self.opacity = 0
refresh
end
def refresh
self.contents.clear
create_contents
@text_size = self.contents.text_size($game_map.map_name).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, $game_map.map_name, 0)
end
def update
super
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, $game_map.map_name, 0)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
class Game_Map
def map_name
return load_data ("Data/MapInfos.rvdata")[$game_map.map_id].name
end
end
#------------------------------------------------------------------------------
# * This draws the Menu Title picture.
#------------------------------------------------------------------------------
class Menu_Title < Window_Base
def initialize
super(0,0,544,155)
self.z = 1
self.opacity = 0
bitmap = Cache.picture(MNK_Picture_Menu::MENU_TITLE_PICTURE[0])
rect = Rect.new(MNK_Picture_Menu::MENU_TITLE_PICTURE[1], 0, 544, 124)
self.contents.blt(x, y, bitmap, rect)
bitmap.dispose
end
end
#------------------------------------------------------------------------------
# * This draws the Menu Bar pictures as well as the large background window.
#------------------------------------------------------------------------------
class Menu_Bar_1 < Window_Base
def initialize
super(0,344,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_2 < Window_Base
def initialize
super(132,344,300,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,237,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_3 < Window_Base
def initialize
super(374,344,170,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,136,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,364,544,52)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Menu_Bar_Pic < Window_Base
def initialize
super(-16,0,580,440)
self.z = 0
self.opacity = 0
self.visible = MNK_Picture_Menu::MENU_BAR_PROPERTIES[4]
bitmap = Cache.picture(MNK_Picture_Menu::MENU_BAR_PROPERTIES[5])
rect = Rect.new(-16, -300, 580, 440)
self.contents.blt(x, y, bitmap, rect)
bitmap.dispose
end
end
#------------------------------------------------------------------------------
# * This actually draws the menu and puts all the other windows where they
# need to be.
#------------------------------------------------------------------------------
class Scene_Menu < Scene_Base
#----------------------------------------------------------------------------
# * Object Initialization
# menu_index : command cursor's initial position
#----------------------------------------------------------------------------
def initialize(menu_index = 0)
@menu_index = menu_index
end
#----------------------------------------------------------------------------
# * Start processing
#----------------------------------------------------------------------------
def start
super
create_menu_background
create_command_window
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
@status_window = Window_MenuStatus.new(80, 0)
@status_window.visible = false
end
#----------------------------------------------------------------------------
# * Termination Processing
#----------------------------------------------------------------------------
def terminate
super
dispose_menu_background
@command_window.dispose
@gold_window.dispose
@status_window.dispose
@time_window.dispose
@titlewindow.dispose
@icon_window.dispose
@map_name_window.dispose
@menubar1.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubar2.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubar3.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == false
@menubarback.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == false
@menubarpic.dispose unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[4] == false
end
#----------------------------------------------------------------------------
# * Frame Update
#----------------------------------------------------------------------------
def update
super
update_menu_background
@command_window.update
@gold_window.update
@status_window.update
@time_window.update
@map_name_window.update
if @command_window.active
update_command_selection
elsif @status_window.active
update_actor_selection
end
end
#----------------------------------------------------------------------------
# * Create Command Window
#----------------------------------------------------------------------------
def create_command_window
s1 = MNK_Picture_Menu::MENU_COMMANDS[0]
s2 = MNK_Picture_Menu::MENU_COMMANDS[1]
s3 = MNK_Picture_Menu::MENU_COMMANDS[2]
s4 = MNK_Picture_Menu::MENU_COMMANDS[3]
s5 = MNK_Picture_Menu::MENU_COMMANDS[4]
s6 = MNK_Picture_Menu::MENU_COMMANDS[5]
s7 = MNK_Picture_Menu::MENU_COMMANDS[6]
s8 = MNK_Picture_Menu::MENU_COMMANDS[7]
if $game_system.save_disabled # If save is forbidden
@command_window = Window_Command.new(180,[s1, s2, s3, s4, s6, s7]) # Remove command from window
else
@command_window = Window_Command.new(180,[s1, s2, s3, s4, s5, s6, s7])
end
@command_window.x = 187
@command_window.y = 125
@command_window.height = 235
@command_window.opacity = 0
@command_window.index = @menu_index
if $game_party.members.size == 0 # If number of party members is 0
@command_window.draw_item(0, false) # Disable item
@command_window.draw_item(1, false) # Disable skill
@command_window.draw_item(2, false) # Disable equipment
@command_window.draw_item(3, false) # Disable status
end
end
#----------------------------------------------------------------------------
# * Update Command Selection
#----------------------------------------------------------------------------
def update_command_selection
if Input.trigger?(Input::B)
Sound.play_cancel
$scene = Scene_Map.new
elsif Input.trigger?(Input::C)
if $game_party.members.size == 0 and @command_window.index < 4
Sound.play_buzzer
return
end
Sound.play_decision
if $game_party.members.size < 2
case @command_window.index
when 0 # Item
$scene = Scene_Item.new
when 1 # skill
$scene = Scene_Skill.new(0)
when 2 # equipment
$scene = Scene_Equip.new(0)
when 3 # status
$scene = Scene_Status.new(0)
when 4
if $game_system.save_disabled
$scene = Scene_End.new
else
$scene = Scene_File.new(true, false, false)
end
when 5
if $game_system.save_disabled
$scene = Scene_Map.new
else
$scene = Scene_End.new
end
when 6
$scene = Scene_Map.new
end
else
case @command_window.index
when 0 # Item
$scene = Scene_Item.new
when 1,2,3 # Skill, equipment, status
@status_window.visible = true
start_actor_selection
when 4
if $game_system.save_disabled
$scene = Scene_End.new
else
$scene = Scene_File.new(true, false, false)
end
when 5
if $game_system.save_disabled
$scene = Scene_Map.new
else
$scene = Scene_End.new
end
when 6
$scene = Scene_Map.new
end
end
end
end
#----------------------------------------------------------------------------
# * Start Actor Selection
#----------------------------------------------------------------------------
def start_actor_selection
@command_window.active = false
@status_window.active = true
if $game_party.last_actor_index < @status_window.item_max
@status_window.index = $game_party.last_actor_index
else
@status_window.index = 0
end
end
#----------------------------------------------------------------------------
# * End Actor Selection
#----------------------------------------------------------------------------
def end_actor_selection
@command_window.active = true
@status_window.active = false
@status_window.index = -1
@status_window.visible = false
end
#----------------------------------------------------------------------------
# * Update Actor Selection
#----------------------------------------------------------------------------
def update_actor_selection
if Input.trigger?(Input::B)
Sound.play_cancel
end_actor_selection
elsif Input.trigger?(Input::C)
$game_party.last_actor_index = @status_window.index
Sound.play_decision
case @command_window.index
when 1 # skill
$scene = Scene_Skill.new(@status_window.index)
when 2 # equipment
$scene = Scene_Equip.new(@status_window.index)
when 3 # status
$scene = Scene_Status.new(@status_window.index)
end
end
end
end
Add-ons
Scene_End Integration Patch
CODE
#------------------------------------------------------------------------------
# * Munkis' DOOM-Style Main Menu Integration Patch for Scene_End V 1.3
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * This makes the window made by Scene_End look integrated into my DOOM-style
# main menu. Will work with my Game End script or the standard Scene_End
# script; may cause problems with YERD Menu System Options.
# * Aliases and overwrites some parts of Scene_End.
# * V 1.0: Initial release
# * V 1.01: Aliased def terminate. You can also now toggle the screen
# darkening when you open the Scene_End Menu.
# * V 1.11: Modified to work with the updated menu script.
# * V 1.2: Modified to work with the updated menu script.
# * V 1.3: Modified to work with the updated menu script.
#------------------------------------------------------------------------------
module MNK_Transparency
TRANSPARENCY = 128
end
class Scene_End < Scene_Base
#--------------------------------------------------------------------------
# * Start processing
#--------------------------------------------------------------------------
alias munkis_start start
def start
munkis_start
super
@command_window.opacity = 0
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
end
#--------------------------------------------------------------------------
# * Termination Processing
#--------------------------------------------------------------------------
alias munkis_terminate terminate
def terminate
munkis_terminate
super
@titlewindow.dispose
@menubar1.dispose
@menubar2.dispose
@menubar3.dispose
@menubarback.dispose
@menubarpic.dispose
@icon_window.dispose
@map_name_window.dispose
@time_window.dispose
@gold_window.dispose
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias munkis_update update
def update
munkis_update
@map_name_window.update
@time_window.update
super
end
end
# * Munkis' DOOM-Style Main Menu Integration Patch for Scene_End V 1.3
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * This makes the window made by Scene_End look integrated into my DOOM-style
# main menu. Will work with my Game End script or the standard Scene_End
# script; may cause problems with YERD Menu System Options.
# * Aliases and overwrites some parts of Scene_End.
# * V 1.0: Initial release
# * V 1.01: Aliased def terminate. You can also now toggle the screen
# darkening when you open the Scene_End Menu.
# * V 1.11: Modified to work with the updated menu script.
# * V 1.2: Modified to work with the updated menu script.
# * V 1.3: Modified to work with the updated menu script.
#------------------------------------------------------------------------------
module MNK_Transparency
TRANSPARENCY = 128
end
class Scene_End < Scene_Base
#--------------------------------------------------------------------------
# * Start processing
#--------------------------------------------------------------------------
alias munkis_start start
def start
munkis_start
super
@command_window.opacity = 0
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
end
#--------------------------------------------------------------------------
# * Termination Processing
#--------------------------------------------------------------------------
alias munkis_terminate terminate
def terminate
munkis_terminate
super
@titlewindow.dispose
@menubar1.dispose
@menubar2.dispose
@menubar3.dispose
@menubarback.dispose
@menubarpic.dispose
@icon_window.dispose
@map_name_window.dispose
@time_window.dispose
@gold_window.dispose
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias munkis_update update
def update
munkis_update
@map_name_window.update
@time_window.update
super
end
end
End Confirm Integration Patch
CODE
#------------------------------------------------------------------------------
# * Munkis' DOOM-Style Main Menu Integration Patch for Munkis_Endgame V 1.45
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * This makes the window made by Munkis_Endgame look integrated into my DOOM-
# style main menu. Aliases some parts of Munkis_Endgame.
# * V 1.0: Initial release
# * V 1.1: Added some code to prevent error messages from popping up if the
# user calls this script from the main title screen. Just turn the
# in-game switch ON to disable the majority of the integration
# features.
# * V 1.2: Edited to include my Difficulty Display window add-on.
# * V 1.3: Modified to work with the updated menu script.
# * V 1.4: Modified to work with the updated menu script.
# * V 1.45: Modified to work with the updated difficulty display script.
#------------------------------------------------------------------------------
module MNK_Patch
TRANSPARENCY = 128
# ADDONS_INCLUDED = [step counter, fight counter, variable window, difficulty display]
ADDONS_INCLUDED = [false, true, false, true]
# Turn this in-game switch ON in Scene_Title to prevent errors.
FROM_TITLE_SWITCH = 2
end
class Munkis_Endgame < Scene_Base
#--------------------------------------------------------------------------
# * Start processing
#--------------------------------------------------------------------------
alias munkis_start_endgame start
def start
munkis_start_endgame
super
unless $imported["KeyboardInput"] == true
@command_window.opacity = 0
end
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
if MNK_Patch::ADDONS_INCLUDED[0] == true
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
if MNK_Patch::ADDONS_INCLUDED[1] == true
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,326)
@menubar5 = Menu_Bar_5.new
end
if MNK_Patch::ADDONS_INCLUDED[2] == true
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
if MNK_Patch::ADDONS_INCLUDED[3] == true
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
end
end
end
#--------------------------------------------------------------------------
# * Termination Processing
#--------------------------------------------------------------------------
alias munkis_terminate_endgame terminate
def terminate
munkis_terminate_endgame
super
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@titlewindow.dispose
@menubar1.dispose
@menubar2.dispose
@menubar3.dispose
@menubarback.dispose
@menubarpic.dispose
@icon_window.dispose
@map_name_window.dispose
@time_window.dispose
@gold_window.dispose
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
if MNK_Patch::ADDONS_INCLUDED[0] == true
@stepwindow.dispose
@menubar4.dispose
end
if MNK_Patch::ADDONS_INCLUDED[1] == true
@fightwindow.dispose
@menubar5.dispose
end
if MNK_Patch::ADDONS_INCLUDED[2] == true
@variablewindow.dispose
@menubar6.dispose
end
if MNK_Patch::ADDONS_INCLUDED[3] == true
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
end
end
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias munkis_update_endgame update
def update
munkis_update_endgame
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@time_window.update
@map_name_window.update
@difdisplayscrolling.update
end
super
end
end
# * Munkis' DOOM-Style Main Menu Integration Patch for Munkis_Endgame V 1.45
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * This makes the window made by Munkis_Endgame look integrated into my DOOM-
# style main menu. Aliases some parts of Munkis_Endgame.
# * V 1.0: Initial release
# * V 1.1: Added some code to prevent error messages from popping up if the
# user calls this script from the main title screen. Just turn the
# in-game switch ON to disable the majority of the integration
# features.
# * V 1.2: Edited to include my Difficulty Display window add-on.
# * V 1.3: Modified to work with the updated menu script.
# * V 1.4: Modified to work with the updated menu script.
# * V 1.45: Modified to work with the updated difficulty display script.
#------------------------------------------------------------------------------
module MNK_Patch
TRANSPARENCY = 128
# ADDONS_INCLUDED = [step counter, fight counter, variable window, difficulty display]
ADDONS_INCLUDED = [false, true, false, true]
# Turn this in-game switch ON in Scene_Title to prevent errors.
FROM_TITLE_SWITCH = 2
end
class Munkis_Endgame < Scene_Base
#--------------------------------------------------------------------------
# * Start processing
#--------------------------------------------------------------------------
alias munkis_start_endgame start
def start
munkis_start_endgame
super
unless $imported["KeyboardInput"] == true
@command_window.opacity = 0
end
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@titlewindow = Menu_Title.new
@menubar1 = Menu_Bar_1.new
@menubar2 = Menu_Bar_2.new
@menubar3 = Menu_Bar_3.new
@menubarback = Menu_Bar_Back.new
@menubarpic = Menu_Bar_Pic.new
@icon_window = Map_Icon_window.new(136, 416)
@map_name_window = Map_Name_window.new(136, 416)
@time_window = Play_Time_window.new(378,360)
@gold_window = Window_Gold.new(0, 360)
@gold_window.opacity = 0
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
if MNK_Patch::ADDONS_INCLUDED[0] == true
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
if MNK_Patch::ADDONS_INCLUDED[1] == true
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,326)
@menubar5 = Menu_Bar_5.new
end
if MNK_Patch::ADDONS_INCLUDED[2] == true
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
if MNK_Patch::ADDONS_INCLUDED[3] == true
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
end
end
end
#--------------------------------------------------------------------------
# * Termination Processing
#--------------------------------------------------------------------------
alias munkis_terminate_endgame terminate
def terminate
munkis_terminate_endgame
super
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@titlewindow.dispose
@menubar1.dispose
@menubar2.dispose
@menubar3.dispose
@menubarback.dispose
@menubarpic.dispose
@icon_window.dispose
@map_name_window.dispose
@time_window.dispose
@gold_window.dispose
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
if MNK_Patch::ADDONS_INCLUDED[0] == true
@stepwindow.dispose
@menubar4.dispose
end
if MNK_Patch::ADDONS_INCLUDED[1] == true
@fightwindow.dispose
@menubar5.dispose
end
if MNK_Patch::ADDONS_INCLUDED[2] == true
@variablewindow.dispose
@menubar6.dispose
end
if MNK_Patch::ADDONS_INCLUDED[3] == true
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
end
end
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias munkis_update_endgame update
def update
munkis_update_endgame
unless $game_switches[MNK_Patch::FROM_TITLE_SWITCH] == true
@time_window.update
@map_name_window.update
@difdisplayscrolling.update
end
super
end
end
Difficulty Setting display (to be used with my Difficulty Select script)
The text will become a scrolling marquee if it's longer than the window.
CODE
#------------------------------------------------------------------------------
# * Munkis' Selected Difficulty Display ADDON V 1.1
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a window to the menu that shows the currently selected difficulty.
# This script grabs the messages used in the difficulty display script
# proper, and can display different icons depending on what difficulty
# setting has been selected.
# * V 1.0: Initial release
# * V 1.1: Added scrolling text function.
#------------------------------------------------------------------------------
module MNK_DifficultyDisplay
#Variable used to switch the displayed difficulty setting
DIF_VAR = 6
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the difficulty display window around in the HUD.
DIF_DISPLAY_WINDOW_X = 5
#Toggle the display of icons with the first value, and change the numbers to
#change what icons are displayed.
DIF_DISPLAY_ICONS = [true,100,101,102,103]
end
class Munkis_Difficulty_Select < Scene_Base
alias choice_1_munkis_dif choice_1
alias choice_2_munkis_dif choice_2
alias choice_3_munkis_dif choice_3
alias choice_4_munkis_dif choice_4
def choice_1
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 0
choice_1_munkis_dif
end
def choice_2
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 1
choice_2_munkis_dif
end
def choice_3
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 2
choice_3_munkis_dif
end
def choice_4
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 3
choice_4_munkis_dif
end
end
class DifDisplay_Static < Window_Base
def initialize (x, y)
super (x+128, y, 395, 32 + WLH)
self.opacity = 0
x, tw = 0, contents.width
if MNK_DifficultyDisplay::DIF_DISPLAY_ICONS[0] == true
draw_icon (MNK_DifficultyDisplay::DIF_DISPLAY_ICONS[$game_variables[MNK_DifficultyDisplay::DIF_VAR]+1], x, 0)
x += 24
tw -= 24
end
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, "Current Setting:")
end
end
class DifDisplay_Scrolling < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+128, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@reset_scroll = false
self.opacity = 0
refresh
end
def refresh
self.contents.clear
create_contents
@text_size = self.contents.text_size(MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]]).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]], 0)
end
def update
super
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]], 0)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
class Menu_Bar_7 < Window_Base
def initialize
super(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(132,15,378,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_2 create_command_window
def create_command_window
munkis_create_command_window_2
@command_window.height = 210
end
alias munkis_dif_start_menu start
def start
munkis_dif_start_menu
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
alias munkis_dif_terminate_menu terminate
def terminate
munkis_dif_terminate_menu
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
alias munkis_dif_update_menu update
def update
munkis_dif_update_menu
@difdisplayscrolling.update
end
end
class Scene_End < Scene_Base
alias munkis_dif_start_end start
def start
munkis_dif_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
end
alias munkis_dif_terminate_end terminate
def terminate
munkis_dif_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
end
alias munkis_dif_update_end update
def update
munkis_dif_update_end
@difdisplayscrolling.update
end
end
# * Munkis' Selected Difficulty Display ADDON V 1.1
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a window to the menu that shows the currently selected difficulty.
# This script grabs the messages used in the difficulty display script
# proper, and can display different icons depending on what difficulty
# setting has been selected.
# * V 1.0: Initial release
# * V 1.1: Added scrolling text function.
#------------------------------------------------------------------------------
module MNK_DifficultyDisplay
#Variable used to switch the displayed difficulty setting
DIF_VAR = 6
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the difficulty display window around in the HUD.
DIF_DISPLAY_WINDOW_X = 5
#Toggle the display of icons with the first value, and change the numbers to
#change what icons are displayed.
DIF_DISPLAY_ICONS = [true,100,101,102,103]
end
class Munkis_Difficulty_Select < Scene_Base
alias choice_1_munkis_dif choice_1
alias choice_2_munkis_dif choice_2
alias choice_3_munkis_dif choice_3
alias choice_4_munkis_dif choice_4
def choice_1
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 0
choice_1_munkis_dif
end
def choice_2
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 1
choice_2_munkis_dif
end
def choice_3
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 2
choice_3_munkis_dif
end
def choice_4
$game_variables[MNK_DifficultyDisplay::DIF_VAR] = 3
choice_4_munkis_dif
end
end
class DifDisplay_Static < Window_Base
def initialize (x, y)
super (x+128, y, 395, 32 + WLH)
self.opacity = 0
x, tw = 0, contents.width
if MNK_DifficultyDisplay::DIF_DISPLAY_ICONS[0] == true
draw_icon (MNK_DifficultyDisplay::DIF_DISPLAY_ICONS[$game_variables[MNK_DifficultyDisplay::DIF_VAR]+1], x, 0)
x += 24
tw -= 24
end
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, "Current Setting:")
end
end
class DifDisplay_Scrolling < Window_Base
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+128, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@reset_scroll = false
self.opacity = 0
refresh
end
def refresh
self.contents.clear
create_contents
@text_size = self.contents.text_size(MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]]).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]], 0)
end
def update
super
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, self.contents.width * 2, 24, MNK_Difficulty_Select::DIFFICULTY_TEXT[$game_variables[MNK_DifficultyDisplay::DIF_VAR]], 0)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
class Menu_Bar_7 < Window_Base
def initialize
super(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(132,15,378,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_2 create_command_window
def create_command_window
munkis_create_command_window_2
@command_window.height = 210
end
alias munkis_dif_start_menu start
def start
munkis_dif_start_menu
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
alias munkis_dif_terminate_menu terminate
def terminate
munkis_dif_terminate_menu
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
alias munkis_dif_update_menu update
def update
munkis_dif_update_menu
@difdisplayscrolling.update
end
end
class Scene_End < Scene_Base
alias munkis_dif_start_end start
def start
munkis_dif_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@difdisplaystatic = DifDisplay_Static.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X,326)
@difdisplayscrolling = DifDisplay_Scrolling.new(MNK_DifficultyDisplay::DIF_DISPLAY_WINDOW_X+170,381)
@menubar7 = Menu_Bar_7.new
end
end
alias munkis_dif_terminate_end terminate
def terminate
munkis_dif_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@difdisplaystatic.dispose
@difdisplayscrolling.dispose
@menubar7.dispose
end
end
alias munkis_dif_update_end update
def update
munkis_dif_update_end
@difdisplayscrolling.update
end
end
Fight/Kill counter
CODE
#------------------------------------------------------------------------------
# * Munkis' Battle Counter ADDON V 1.2 -- Yggdrasil compatible version
# * Made by munkis
# �•”�•��•��•��•��•��•��•��•��•��•��•—
# �•‘ FEATURES �•‘
# �•š�•��•��•��•��•��•��•��•��•��•��•�
# * Adds a battle counter window to the main menu HUD. This script is really
# just a specialized version of the Variable Window script, but I felt it
# was important and useful enough to share. This version can count kills
# made in IceDragon's Yggdrasil CBS by setting YGGDRASIL_PRESENT to true;
# setting it to true without Yggdrasil in your game will result in
# uninitialized constant errors.
# * V 1.0: Initial release
# * V 1.1: Made to count kills made in IceDragon's Yggdrasil CBS.
# * V 1.2: Updated for compatibility with Yggdrasil 1.6
#------------------------------------------------------------------------------
module MNK_Picture_Menu
#In-game variable used to add up the victories.
FIGHTVAR = 5
FIGHTCOUNT_ICON = 9
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
FIGHTCOUNT_WINDOW_X = 77
#set this to true if you're using IceDragon's Yggdrasil CBS.
YGGDRASIL_PRESENT = true
end
class FightCount < Window_Base
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Object Initialization
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
refresh
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def refresh
x, tw = 0, contents.width
# Draw varibale icon
if MNK_Picture_Menu::FIGHTCOUNT_ICON >= 0
draw_icon (MNK_Picture_Menu::FIGHTCOUNT_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Variable
text = $game_variables[MNK_Picture_Menu::FIGHTVAR].to_s
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, text, 2)
end
end
class Menu_Bar_5 < Window_Base
def initialize
super(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X - 5,348,640,480)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,640,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_1 create_command_window
def create_command_window
munkis_create_command_window_1
@command_window.height = 210
end
alias munkis_fight_start_menu start
def start
munkis_fight_start_menu
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,366)
@menubar5 = Menu_Bar_5.new
end
alias munkis_fight_terminate_menu terminate
def terminate
munkis_fight_terminate_menu
@fightwindow.dispose
@menubar5.dispose
end
end
class Scene_End < Scene_Base
alias munkis_fight_start_end start
def start
munkis_fight_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,366)
@menubar5 = Menu_Bar_5.new
end
end
alias munkis_fight_terminate_end terminate
def terminate
munkis_fight_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@fightwindow.dispose
@menubar5.dispose
end
end
end
class Scene_Battle < Scene_Base
alias munkis_victory process_victory
def process_victory
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
munkis_victory
end
end
if MNK_Picture_Menu::YGGDRASIL_PRESENT == true
class Game_Event < Game_Character
alias ygg_perform_death_munkis ygg_perform_death
if $imported["IRME_Event_Generator"]
def ygg_perform_death()
ygg_perform_death_munkis()
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
end
else
def ygg_perform_death()
ygg_perform_death_munkis()
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
end
end
end
end
# * Munkis' Battle Counter ADDON V 1.2 -- Yggdrasil compatible version
# * Made by munkis
# �•”�•��•��•��•��•��•��•��•��•��•��•—
# �•‘ FEATURES �•‘
# �•š�•��•��•��•��•��•��•��•��•��•��•�
# * Adds a battle counter window to the main menu HUD. This script is really
# just a specialized version of the Variable Window script, but I felt it
# was important and useful enough to share. This version can count kills
# made in IceDragon's Yggdrasil CBS by setting YGGDRASIL_PRESENT to true;
# setting it to true without Yggdrasil in your game will result in
# uninitialized constant errors.
# * V 1.0: Initial release
# * V 1.1: Made to count kills made in IceDragon's Yggdrasil CBS.
# * V 1.2: Updated for compatibility with Yggdrasil 1.6
#------------------------------------------------------------------------------
module MNK_Picture_Menu
#In-game variable used to add up the victories.
FIGHTVAR = 5
FIGHTCOUNT_ICON = 9
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
FIGHTCOUNT_WINDOW_X = 77
#set this to true if you're using IceDragon's Yggdrasil CBS.
YGGDRASIL_PRESENT = true
end
class FightCount < Window_Base
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Object Initialization
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
refresh
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def refresh
x, tw = 0, contents.width
# Draw varibale icon
if MNK_Picture_Menu::FIGHTCOUNT_ICON >= 0
draw_icon (MNK_Picture_Menu::FIGHTCOUNT_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Variable
text = $game_variables[MNK_Picture_Menu::FIGHTVAR].to_s
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, text, 2)
end
end
class Menu_Bar_5 < Window_Base
def initialize
super(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X - 5,348,640,480)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,640,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_1 create_command_window
def create_command_window
munkis_create_command_window_1
@command_window.height = 210
end
alias munkis_fight_start_menu start
def start
munkis_fight_start_menu
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,366)
@menubar5 = Menu_Bar_5.new
end
alias munkis_fight_terminate_menu terminate
def terminate
munkis_fight_terminate_menu
@fightwindow.dispose
@menubar5.dispose
end
end
class Scene_End < Scene_Base
alias munkis_fight_start_end start
def start
munkis_fight_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@fightwindow = FightCount.new(MNK_Picture_Menu::FIGHTCOUNT_WINDOW_X,366)
@menubar5 = Menu_Bar_5.new
end
end
alias munkis_fight_terminate_end terminate
def terminate
munkis_fight_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@fightwindow.dispose
@menubar5.dispose
end
end
end
class Scene_Battle < Scene_Base
alias munkis_victory process_victory
def process_victory
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
munkis_victory
end
end
if MNK_Picture_Menu::YGGDRASIL_PRESENT == true
class Game_Event < Game_Character
alias ygg_perform_death_munkis ygg_perform_death
if $imported["IRME_Event_Generator"]
def ygg_perform_death()
ygg_perform_death_munkis()
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
end
else
def ygg_perform_death()
ygg_perform_death_munkis()
$game_variables[MNK_Picture_Menu::FIGHTVAR] += 1
end
end
end
end
Step counter
CODE
#------------------------------------------------------------------------------
# * Munkis' Stepcount ADDON V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a stepcount window to the main menu HUD.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
module MNK_Picture_Menu
STEPCOUNT_ICON = 48
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
STEPCOUNT_WINDOW_X = 5
end
class StepCount < Window_Base
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
x, tw = 0, contents.width
# Draw step count icon
if MNK_Picture_Menu::STEPCOUNT_ICON >= 0
draw_icon (MNK_Picture_Menu::STEPCOUNT_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Step Count
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, $game_party.steps.to_s, 2)
end
end
class Menu_Bar_4 < Window_Base
def initialize
super(MNK_Picture_Menu::STEPCOUNT_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window create_command_window
def create_command_window
munkis_create_command_window
@command_window.height = 210
end
alias munkis_step_start_menu start
def start
munkis_step_start_menu
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
alias munkis_step_terminate_menu terminate
def terminate
munkis_step_terminate_menu
@stepwindow.dispose
@menubar4.dispose
end
end
class Scene_End < Scene_Base
alias munkis_step_start_end start
def start
munkis_step_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
end
alias munkis_step_terminate_end terminate
def terminate
munkis_step_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@stepwindow.dispose
@menubar4.dispose
end
end
end
# * Munkis' Stepcount ADDON V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a stepcount window to the main menu HUD.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
module MNK_Picture_Menu
STEPCOUNT_ICON = 48
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
STEPCOUNT_WINDOW_X = 5
end
class StepCount < Window_Base
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
x, tw = 0, contents.width
# Draw step count icon
if MNK_Picture_Menu::STEPCOUNT_ICON >= 0
draw_icon (MNK_Picture_Menu::STEPCOUNT_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Step Count
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, $game_party.steps.to_s, 2)
end
end
class Menu_Bar_4 < Window_Base
def initialize
super(MNK_Picture_Menu::STEPCOUNT_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window create_command_window
def create_command_window
munkis_create_command_window
@command_window.height = 210
end
alias munkis_step_start_menu start
def start
munkis_step_start_menu
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
alias munkis_step_terminate_menu terminate
def terminate
munkis_step_terminate_menu
@stepwindow.dispose
@menubar4.dispose
end
end
class Scene_End < Scene_Base
alias munkis_step_start_end start
def start
munkis_step_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@stepwindow = StepCount.new(MNK_Picture_Menu::STEPCOUNT_WINDOW_X,326)
@menubar4 = Menu_Bar_4.new
end
end
alias munkis_step_terminate_end terminate
def terminate
munkis_step_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@stepwindow.dispose
@menubar4.dispose
end
end
end
Variable Window
CODE
#------------------------------------------------------------------------------
# * Munkis' Variable Window ADDON V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a variable window to the main menu HUD. Just tell this script what
# in-game variable vou want to use, and mess with the variable through
# normal eventing.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
module MNK_Picture_Menu
#In-game variable used to add up the... whatever it is you're adding up.
WINDOWVAR = 1
VARWINDOW_ICON = 99
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
VARIABLE_WINDOW_X = 379
end
class VariableWindow < Window_Base
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Object Initialization
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
refresh
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def refresh
x, tw = 0, contents.width
# Draw varibale icon
if MNK_Picture_Menu::VARWINDOW_ICON >= 0
draw_icon (MNK_Picture_Menu::VARWINDOW_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Variable
text = $game_variables[MNK_Picture_Menu::WINDOWVAR].to_s
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, text, 2)
end
end
class Menu_Bar_6 < Window_Base
def initialize
super(MNK_Picture_Menu::VARIABLE_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_2 create_command_window
def create_command_window
munkis_create_command_window_2
@command_window.height = 210
end
alias munkis_variable_start_menu start
def start
munkis_variable_start_menu
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
alias munkis_variable_terminate_menu terminate
def terminate
munkis_variable_terminate_menu
@variablewindow.dispose
@menubar6.dispose
end
end
class Scene_End < Scene_Base
alias munkis_variable_start_end start
def start
munkis_variable_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
end
alias munkis_variable_terminate_end terminate
def terminate
munkis_variable_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@variablewindow.dispose
@menubar6.dispose
end
end
end
# * Munkis' Variable Window ADDON V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Adds a variable window to the main menu HUD. Just tell this script what
# in-game variable vou want to use, and mess with the variable through
# normal eventing.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
module MNK_Picture_Menu
#In-game variable used to add up the... whatever it is you're adding up.
WINDOWVAR = 1
VARWINDOW_ICON = 99
#Set this to TRUE if you're using my Game End Integration Patch.
ENABLE_INTEGRATION = true
#Change this value to slide the StepCount window around in the HUD.
VARIABLE_WINDOW_X = 379
end
class VariableWindow < Window_Base
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Object Initialization
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def initialize (x, y)
super (x, y, 150, 32 + WLH)
self.opacity = 0
refresh
end
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# * Refresh
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
def refresh
x, tw = 0, contents.width
# Draw varibale icon
if MNK_Picture_Menu::VARWINDOW_ICON >= 0
draw_icon (MNK_Picture_Menu::VARWINDOW_ICON, x, 0)
x += 24
tw -= 24
end
# Draw Variable
text = $game_variables[MNK_Picture_Menu::WINDOWVAR].to_s
contents.font.color = normal_color
contents.draw_text (x, 0, tw, WLH, text, 2)
end
end
class Menu_Bar_6 < Window_Base
def initialize
super(MNK_Picture_Menu::VARIABLE_WINDOW_X - 5,310,544,416)
self.z = 1
self.opacity = 0
if MNK_Picture_Menu::MENU_BAR_PROPERTIES[0] == true
rect = Rect.new(0,15,128,29)
contents.fill_rect(rect, MNK_Picture_Menu::MENU_BAR_PROPERTIES[2])
lsize = 2 # Line Size
lcolor = MNK_Picture_Menu::MENU_BAR_PROPERTIES[3] # Line Color
contents.fill_rect(rect.x, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y, rect.width, lsize, lcolor)
contents.fill_rect(rect.x + rect.width - lsize, rect.y, lsize, rect.height, lcolor)
contents.fill_rect(rect.x, rect.y + rect.height - lsize, rect.width, lsize, lcolor)
end
end
end
class Menu_Bar_Back < Window_Base
def initialize
super(0,329,544,87)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
class Scene_Menu < Scene_Base
alias munkis_create_command_window_2 create_command_window
def create_command_window
munkis_create_command_window_2
@command_window.height = 210
end
alias munkis_variable_start_menu start
def start
munkis_variable_start_menu
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
alias munkis_variable_terminate_menu terminate
def terminate
munkis_variable_terminate_menu
@variablewindow.dispose
@menubar6.dispose
end
end
class Scene_End < Scene_Base
alias munkis_variable_start_end start
def start
munkis_variable_start_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@variablewindow = Variablewindow.new(MNK_Picture_Menu::VARIABLE_WINDOW_X,326)
@menubar6 = Menu_Bar_6.new
end
end
alias munkis_variable_terminate_end terminate
def terminate
munkis_variable_terminate_end
if MNK_Picture_Menu::ENABLE_INTEGRATION == true
@variablewindow.dispose
@menubar6.dispose
end
end
end
Menu_Bar_Back expander snippet (useful if you have 3 rows of HUD windows)
CODE
#------------------------------------------------------------------------------
# * Munkis' Menu_Bar_Back 3-row snippet V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Basically all this script does is re-size the menu bar to fit 3 rows of
# add-on displays. Place this snippet BELOW the main menu script AND all
# add-on scripts.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
class Menu_Bar_Back < Window_Base
def initialize
super(0,290,544,131)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
# * Munkis' Menu_Bar_Back 3-row snippet V 1.0
# * Made by munkis
# •”•••••••••••—
# •‘ FEATURES •‘
# •š•••••••••••
# * Basically all this script does is re-size the menu bar to fit 3 rows of
# add-on displays. Place this snippet BELOW the main menu script AND all
# add-on scripts.
# * V 1.0: Initial release
#------------------------------------------------------------------------------
class Menu_Bar_Back < Window_Base
def initialize
super(0,290,544,131)
self.z = 0
self.opacity = 0 unless MNK_Picture_Menu::MENU_BAR_PROPERTIES[1] == true
end
end
Scrolling Area Name patch for Map Name Window (useful if you put all of your interior maps on one giant map -- Made by Night Runner)
CODE
#==============================================================================
# ** Night_Runner's Doom Menu Map Name & Area Window
#------------------------------------------------------------------------------
# History:
# Date Created: 31/Oct/2011
# Created for: munkis
# @> http://www.rpgrevolution.com/forums/index.php?showtopic=53598
#
# Description:
# This script is an add on to the Doom Menu script, and instead of
# showing just the map name it shows the map name and the area of the
# player inside the map (if an area is set up).
#
# How to Install:
# Copy this entire script. In your game's editor select Tools >>
# Script Editor. Along the left side scroll all the way to the bottom,
# right click on 'Main' and select 'Insert'. Paste this code on the
# right.
#==============================================================================
#==============================================================================
# Game_Map
#==============================================================================
class Game_Map
#--------------------------------------------------------------------------
# Class Variables
#--------------------------------------------------------------------------
@@areas_list = []
#--------------------------------------------------------------------------
# * Determine if in Area
# area : Area data (RPG::Area)
#--------------------------------------------------------------------------
def in_area?(area)
return false if not area.is_a?(RPG::Area)
return false if $game_map.map_id != area.map_id
px, py = $game_player.x, $game_player.y
return false if px < area.rect.x
return false if py < area.rect.y
return false if px >= area.rect.x + area.rect.width
return false if py >= area.rect.y + area.rect.height
return true
end
#--------------------------------------------------------------------------
# Get Area Name
#--------------------------------------------------------------------------
def area_name
# Do nothing if there's no areas
return "" if $data_areas.empty?
# Initialize the areas list if appropriate
@@areas_list = $data_areas.values.clone if @@areas_list.empty?
# Initialize a variable for area that is inhabited
inhabited_area = nil
# Loop through the areas
for area in @@areas_list
# If the player is in the area, save it and break the loop
if in_area?(area)
inhabited_area = area
break
end
end
# Do nothing if the area doesn't exist
return "" if inhabited_area.nil?
# Move this area to the start of the @@areas_list (speed performance)
@@areas_list.delete(inhabited_area)
@@areas_list.insert(0, inhabited_area)
# Return this area name
return area.name
end
end
#==============================================================================
# ** Map_Name_Window
#------------------------------------------------------------------------------
# Edited to show the area name.
#==============================================================================
class Map_Name_Window < Window_Base
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+30, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@frames_since_refresh = 0
@reset_scroll = false
self.opacity = 0
refresh
end
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
create_contents
@text = $game_map.map_name
if $game_map.area_name != ""
@text = $game_map.area_name
end
@text_size = self.contents.text_size(@text).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, @text_size + 64, 24, @text, 0)
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
super
@frames_since_refresh += 1
if @frames_since_refresh > 60
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, @text_size + 64, 24, @text)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
end
#==============================================================================
# ** End of Script.
#==============================================================================
# ** Night_Runner's Doom Menu Map Name & Area Window
#------------------------------------------------------------------------------
# History:
# Date Created: 31/Oct/2011
# Created for: munkis
# @> http://www.rpgrevolution.com/forums/index.php?showtopic=53598
#
# Description:
# This script is an add on to the Doom Menu script, and instead of
# showing just the map name it shows the map name and the area of the
# player inside the map (if an area is set up).
#
# How to Install:
# Copy this entire script. In your game's editor select Tools >>
# Script Editor. Along the left side scroll all the way to the bottom,
# right click on 'Main' and select 'Insert'. Paste this code on the
# right.
#==============================================================================
#==============================================================================
# Game_Map
#==============================================================================
class Game_Map
#--------------------------------------------------------------------------
# Class Variables
#--------------------------------------------------------------------------
@@areas_list = []
#--------------------------------------------------------------------------
# * Determine if in Area
# area : Area data (RPG::Area)
#--------------------------------------------------------------------------
def in_area?(area)
return false if not area.is_a?(RPG::Area)
return false if $game_map.map_id != area.map_id
px, py = $game_player.x, $game_player.y
return false if px < area.rect.x
return false if py < area.rect.y
return false if px >= area.rect.x + area.rect.width
return false if py >= area.rect.y + area.rect.height
return true
end
#--------------------------------------------------------------------------
# Get Area Name
#--------------------------------------------------------------------------
def area_name
# Do nothing if there's no areas
return "" if $data_areas.empty?
# Initialize the areas list if appropriate
@@areas_list = $data_areas.values.clone if @@areas_list.empty?
# Initialize a variable for area that is inhabited
inhabited_area = nil
# Loop through the areas
for area in @@areas_list
# If the player is in the area, save it and break the loop
if in_area?(area)
inhabited_area = area
break
end
end
# Do nothing if the area doesn't exist
return "" if inhabited_area.nil?
# Move this area to the start of the @@areas_list (speed performance)
@@areas_list.delete(inhabited_area)
@@areas_list.insert(0, inhabited_area)
# Return this area name
return area.name
end
end
#==============================================================================
# ** Map_Name_Window
#------------------------------------------------------------------------------
# Edited to show the area name.
#==============================================================================
class Map_Name_Window < Window_Base
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize (x, y)
height = 32 + WLH
y -= height
super (x+30, y, 228, 32+WLH)
@text_size = 0
@scroll_amount = 0
@scroll_delay = 0
@current_x = 0
@frames_since_refresh = 0
@reset_scroll = false
self.opacity = 0
refresh
end
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
create_contents
@text = $game_map.map_name
if $game_map.area_name != ""
@text = $game_map.area_name
end
@text_size = self.contents.text_size(@text).width
if @text_size > self.contents.width
@scroll_amount = @text_size
end
self.contents.draw_text(@current_x, 0, @text_size + 64, 24, @text, 0)
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
super
@frames_since_refresh += 1
if @frames_since_refresh > 60
if @scroll_amount > 0
@scroll_delay -= 1 unless @scroll_delay == 0
if @scroll_delay == 0
@current_x -= @scroll_amount / MNK_Picture_Menu::MAP_NAME_SCROLL
self.contents.clear
self.contents.draw_text(@current_x, 0, @text_size + 64, 24, @text)
@scroll_delay = MNK_Picture_Menu::MAP_NAME_SCROLL / 2
if -@current_x >= @scroll_amount
@reset_scroll = true
end
end
if @reset_scroll
@current_x = self.contents.width
@reset_scroll = false
end
end
end
end
end
#==============================================================================
# ** End of Script.
#==============================================================================
Customization
Just take a peek at the config modules of the menu script and any add-ons you may use.
Compatibility
Overwrites Scene_Menu.
Screenshot

(This screenshot doesn't include any of the add-ons.)
DEMO
This script is more simple to use than it looks...
Installation
Place in MATERIALS, above MAIN.
FAQ
Q: ZOMG teh scriptz doesn't werk!!!
A: First of all, be more specific. Second, all reports typed in chat-speak or 1337-speak will be ignored.
Terms and Conditions
I don't mind this script being posted or linked on other sites AS LONG AS YOU GIVE CREDIT!!! Same goes for using this in your project. Contact me if you want to use this in a commercial project.
Credits
Credit me (munkis).
EDIT: Fixed a couple of typos in the script.