Wizered67's Speed Menu
Authors: Wizered67
Version: 0.30
Type: On-map Menu System
Key Term: Custom Menu System
IntroductionHello, and welcome to my first script. I understand that it is probably not very good and messy, but I wanted to post it anyway. (At least for critique). Recently, I have noticed an increase in the amount of people trying to make an online game with
RMX-OS and Blizz-abs. However, one common problem is that the default menu (and most others) pause the game while other players continue to play and take advantage of this. I know this from experience, as I too am trying to create a game like this, and this has been a major setback. Thereofre, I began looking through google. However, I only could find one script (which btw required SDK
) that did what I needed it to. This was ztorm's speed menu. However, the demo was missing. therefore, I attempted to learn scripting to make the script I needed. I don't know if anyone will use it, but oh well
Features
- On-map menu
- doesn't pause game
- my first script
Right now, I haven't made special windows for item, equip, skills , etc and plan on adding that later. (Note how its only version 0.30)
Screenshots
DemoNone yet, but I can make one
ScriptPlace the script above main, but below menu and map scenes.
#------------------------------------------------------------------------------
#This is my Speed Menu by Wizered67. If you have any questions,
#visit www.chaos-project.com. To show the menu on the map,
#you press shift. To move the cursor over or select an option, you have
#to hold down control and move the arrow keys. I hope this is easy enough and works
#fine. This curently doesn't support mouse control or have any of the scenes.
##############################################################################
#SPEED MENU
#By Wizered67
#version 0.30
##############################################################################
#-------------------------------------------------------------------------------
#==============================================================================
# ** Window_Speed_Menu
#------------------------------------------------------------------------------
# This window displays the menu in a window like format on the map instead
# of the menu scene.
#==============================================================================
class Window_Speed_Menu < Window_Selectable
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(0, 64, 640, 64)
self.contents = Bitmap.new(width - 32, height - 32)
@item_max = 5
@column_max = 4
@commands = ["Item", "Skill", "Equip","Status","End Game"]
refresh
self.index = 0
end
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
for i in 0...@item_max
draw_item(i)
end
end
#--------------------------------------------------------------------------
# * Draw Item
# index : item number
#--------------------------------------------------------------------------
def draw_item(index)
x = 4 + index * 160
self.contents.draw_text(x, 0, 128, 32, @commands[index])
end
end
#-----------------------------------------------------------------------------
# Update Menu
#-----------------------------------------------------------------------------
def update_speed_menu
#-------------------------------------------------------------------------
#Check for input (Select Choice)
#-------------------------------------------------------------------------
if Input.press?(Input::Key['Ctrl'])
if Input.trigger?(Input::C)
case @window_speed_menu.index
when 0
$game_system.se_play($data_system.decision_se)
@window_speed_menu.active = false
@window_speed_menu.visible = false
$speed_menu_showing = false
$scene = Scene_Item.new
when 1
$game_system.se_play($data_system.decision_se)
@window_speed_menu.active = false
@window_speed_menu.visible = false
$speed_menu_showing = false
$scene = Scene_Skill.new
when 2
$game_system.se_play($data_system.decision_se)
@window_speed_menu.active = false
@window_speed_menu.visible = false
$speed_menu_showing = false
$scene = Scene_Equip.new
when 3
$status_window_showing = true
$game_system.se_play($data_system.decision_se)
@window_speed_menu.active = false
@window_speed_menu.visible = false
@status_window = Window_MenuStatus.new
$speed_menu_showing = false
@status_window.opacity = 160
@window_gold = Window_Gold.new
@window_gold.opacity = 160
@window_gold.x = 480
@window_gold.y = 350
when 4
$game_system.se_play($data_system.decision_se)
@window_speed_menu.active = false
@window_speed_menu.visible = false
$speed_menu_showing = false
$scene = Scene_End.new
end
end
end
#-----------------------------------------------------------------------
#Check for Escape Key
#-----------------------------------------------------------------------
if Input.trigger?(Input::Key['Esc']) and ($speed_menu_showing == true or $status_window_showing == true)
if @window_speed_menu.visible == true
@window_speed_menu.active = false
@window_speed_menu.visible = false
$speed_menu_showing = false
end
if $status_window_showing == true
@window_gold.dispose
@status_window.dispose
$status_window_showing = false
end
end
#-------------------------------------------------------------------------
#Check for input (Move cursor)
#-------------------------------------------------------------------------
if Input.press?(Input::Key['Ctrl'])
if Input.trigger?(Input::RIGHT)
@window_speed_menu.active = true
unless @window_speed_menu.index == 3
$game_system.se_play($data_system.cursor_se)
@window_speed_menu.index += 1
else
$game_system.se_play($data_system.cursor_se)
@window_speed_menu.index = 0
end
end
if Input.trigger?(Input::LEFT)
@window_speed_menu.active = true
unless @window_speed_menu.index <= 0
$game_system.se_play($data_system.cursor_se)
@window_speed_menu.index -= 1
else
$game_system.se_play($data_system.cursor_se)
@window_speed_menu.index = 3
end
end
end
end
#--------------------------------------------------------------------
#Scene_Map
# def update
# This part of the scene was put into this script with slight differences for plug and play.
#---------------------------------------------------------------------
class Scene_Map
def update
# Loop
loop do
# Update map, interpreter, and player order
# (this update order is important for when conditions are fulfilled
# to run any event, and the player isn't provided the opportunity to
# move in an instant)
$game_map.update
$game_system.map_interpreter.update
$game_player.update
# Update system (timer), screen
$game_system.update
$game_screen.update
if @window_speed_menu
@window_speed_menu.active = true
update_speed_menu
end
# Abort loop if player isn't place moving
unless $game_temp.player_transferring
break
end
# Run place move
transfer_player
# Abort loop if transition processing
if $game_temp.transition_processing
break
end
end
# Update sprite set
@spriteset.update
# Update message window
@message_window.update
# If game over
if $game_temp.gameover
# Switch to game over screen
$scene = Scene_Gameover.new
return
end
# If returning to title screen
if $game_temp.to_title
# Change to title screen
$scene = Scene_Title.new
return
end
# If transition processing
if $game_temp.transition_processing
# Clear transition processing flag
$game_temp.transition_processing = false
# Execute transition
if $game_temp.transition_name == ""
Graphics.transition(20)
else
Graphics.transition(40, "Graphics/Transitions/" +
$game_temp.transition_name)
end
end
# If showing message window
if $game_temp.message_window_showing
return
end
# If encounter list isn't empty, and encounter count is 0
if $game_player.encounter_count == 0 and $game_map.encounter_list != []
# If event is running or encounter is not forbidden
unless $game_system.map_interpreter.running? or
$game_system.encounter_disabled
# Confirm troop
n = rand($game_map.encounter_list.size)
troop_id = $game_map.encounter_list[n]
# If troop is valid
if $data_troops[troop_id] != nil
# Set battle calling flag
$game_temp.battle_calling = true
$game_temp.battle_troop_id = troop_id
$game_temp.battle_can_escape = true
$game_temp.battle_can_lose = false
$game_temp.battle_proc = nil
end
end
end
# If B button was pressed
if Input.trigger?(Input::B)
# If event is running, or menu is not forbidden
unless $game_system.map_interpreter.running? or
$game_system.menu_disabled
# Set menu calling flag or beep flag
# $game_temp.menu_calling = true
#$game_temp.menu_beep = true
end
end
if Input.trigger?(Input::A) && ($speed_menu_showing != true)
$speed_menu_showing = true
@window_speed_menu = Window_Speed_Menu.new
@window_speed_menu.active = true
@window_speed_menu.visible = true
@window_speed_menu.opacity = 140
end
# If debug mode is ON and F9 key was pressed
if $DEBUG and Input.press?(Input::F9)
# Set debug calling flag
$game_temp.debug_calling = true
end
# If player is not moving
unless $game_player.moving?
# Run calling of each screen
if $game_temp.battle_calling
call_battle
elsif $game_temp.shop_calling
call_shop
elsif $game_temp.name_calling
call_name
elsif $game_temp.menu_calling
call_menu
elsif $game_temp.save_calling
call_save
elsif $game_temp.debug_calling
call_debug
end
end
end
end
#----------------------
#End Scene Map
#----------------------
#---------------------------------------
#Scene_Menu
# This is just a small edit so that you can't go to the menu scene
#----------------------------------------
class Scene_Menu
def main
$scene = Scene_Map.new
end
end
InstructionsTo open the menu, press shift. To move cursor or select on the menu you MUST be holding down ctrl.
CompatibilityRequires Tons ,Blizz-abs ,or RMX-OS for custom controls
None other issues known.
Credits and Thanks
- Wizered67, me
- Blizzard for inspiring me
- Ztorm for the inspiration to make my own speed menu when his demo was missing.
Author's NotesThis is my first script. I don't really expect anyone to use it, but I figured I might as well post it to get critique. Hit me with your best shot!