Hmm yes then it would surpass the max stat. What would be the best way?
Yes, maybe wouldn't mean much but does look visually pleasing
Yes, maybe wouldn't mean much but does look visually pleasing
col_max to return 1.Using that, for me, it stays stuck on the first command selected. it doesn't even seem to process any input options, except for enter hahaha
#==============================================================================
# ** Window_TitleCommand
#------------------------------------------------------------------------------
# This window is for selecting New Game/Continue on the title screen.
#==============================================================================
class Window_TitleCommand < Window_HorzCommand
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(0, 0)
update_placement
select_symbol(:continue) if continue_enabled
self.openness = 0
open
end
#--------------------------------------------------------------------------
# * Get Window Width
#--------------------------------------------------------------------------
def window_width
return 160
end
#--------------------------------------------------------------------------
# * overwrite
#--------------------------------------------------------------------------
def col_max
return 1
end
#--------------------------------------------------------------------------
# * Update Window Position
#--------------------------------------------------------------------------
def update_placement
self.x = (Graphics.width - width) / 2
self.y = (Graphics.height * 1.6 - height) / 2
end
#--------------------------------------------------------------------------
# * Create Command List
#--------------------------------------------------------------------------
def make_command_list
add_command(Vocab::new_game, :new_game)
add_command(Vocab::continue, :continue, continue_enabled)
add_command(Vocab::shutdown, :shutdown)
end
#--------------------------------------------------------------------------
# * Get Activation State of Continue
#--------------------------------------------------------------------------
def continue_enabled
DataManager.save_file_exists?
end
end
class Window_SingleHorzCommand < Window_HorzCommand
def col_max; return 1; end
def draw_all_items
draw_item(@index)
end
def select(index)
super
refresh_cell
end
def draw_item(index)
change_color(normal_color, command_enabled?(index))
draw_text(item_rect_for_text(0), command_name(index), alignment)
end
def cursor_right(wrap = false)
if (index < item_max - 1 || (wrap && horizontal?))
select((index + 1) % item_max)
end
end
def cursor_left(wrap = false)
if (index > 0 || (wrap && horizontal?))
select((index - 1 + item_max) % item_max)
end
end
def update_cursor
if @cursor_all
cursor_rect.set(0, 0, contents.width, row_max * item_height)
self.top_row = 0
elsif @index < 0
cursor_rect.empty
else
ensure_cursor_visible
cursor_rect.set(item_rect(0))
end
end
def refresh_cell
clear_item(0)
draw_all_items
end
end
thank you! What license does this script have? Do you have a name/URL you want to be credited to?
Original thread: https://forums.rpgmakerweb.com/threads/ruby-rgssx-questions-that-dont-deserve-their-own-thread.150/