Broken Messiah 20 Report post Posted April 21, 2011 I've looked around for this to no luck, so I figured I'd asked here: I want a menu that contains a list of available missions, each categorized into diffuculty, I made a simple flash to help you understand what I mean: What Im aiming for Here is the image in it: It also has to be compatible with woratanas quest script Thank you Share this post Link to post Share on other sites
kellessdee 48 Report post Posted April 21, 2011 I have to head off to work in a little bit, but if no one has answered by the time I am back, I should be able to put something together. It may take me a little bit, I would have to get rmvx's trial or at least the help manual to determine the differences in the pre-defined classes. Share this post Link to post Share on other sites
Broken Messiah 20 Report post Posted April 21, 2011 From my basic knowlegde of rgss2, a few modules were taken out and combined, and the windows have a few more features. Share this post Link to post Share on other sites
rgangsta 43 Report post Posted April 21, 2011 I have something along those lines. It looks like this: #=========================\__________________________/=========================# ##========================/ \========================## #/ / / / / / / / / / / / / \ \ \ \ \ \ \ \ \ \ \ \ \# #/ SOV - Map Selection \# #/ \# #|----------------------------------------------------------------------------|# #\ Started : 15/10/09 /# #\ Finished: 21/10/09 By SuperOverlord /# #\ \ \ \ \ \ \ \ \ \ \ \ \ / / / / / / / / / / / / /# ##========================\__________________________/========================## #=========================/ \=========================# #==============================================================================# # Features: # #------------------------------------------------------------------------------# # - Selection of maps to transfer to in 3 different ways: # # - when new game is chosen in Scene_Title # # - from the menu # # - using a script call # # You can change where it's available from at any time using script calls. # # # # - Using these it should be possible to use this script in a variety of ways: # # - Missions select, which would either bring a player to a map. # # Use the return map command from the menu to return to the original # # map. The missions could either be opened from an event or the menu. # # - Ability to switch map at any time. Uncover hidden maps or unlock locked # # ones. # # - A main level hub. Like with missions, only use an event to open the menu # # from one main map. Use return map command to return to this hub map. # # # # - Set a list of map transfers in the customisation section. # # They have 3 availability settings as follows: # # - locked maps - showing but unavailable # # - hidden maps - not included # # - If neither of the above, available to select. # # # # - Use script calls to toggle between locked, unlocked or hidden, showing at # # any time. # # # # - Each map has it's own set bitmap and description. # # # #==============================================================================# # Instructions: # #------------------------------------------------------------------------------# # - Place above main and below materials. # # # # - If you find any bugs: # # - Check over the customisable section for incorrect entries. # # - Not fixed? Now try the script in a blank project. # # - Did it work? # # Yes - It's a compatibility issue. Try deleting you're scripts one at a # # time and playtesting to find which one(s) are causing the error. # # No - Please post the error, line and any other useful information at # # the scripts topic and I'll try to fix whatever's wrong. # # # # - Once it's working, scroll down to customisation and edit as you please. # # # # - See below for info on note tags, script calls,etc. # # # #==============================================================================# # Script Calls: # #------------------------------------------------------------------------------# # The indexes below refer to the map transfer's index in the customisation # # section. 0 is the first one. 1 is the second and so on. # # # # - To switch the locked state of the map transfer with name == name: # # switch_locked_name(name) # # - To switch the locked state of the map transfer with index == index: # # switch_locked_index(index) # # # # - To switch the hidden state of the map transfer with name == name: # # switch_hidden_name(name) # # - To switch the hidden state of the map transfer with index == index: # # switch_hidden_index(index) # # # # - Open Map selection screen: # # open_selection_screen # # # # - Grey out the map selection command from the menu: # # disable_map_selection # # - Make map selection command available: # # enable_map_selection # # # # - Grey out the return map command from the quit submenu: # # disable_map_return # # - Make return map command available from the quit submenu: # # enable_map_return # # # #==============================================================================# # FAQ # #------------------------------------------------------------------------------# # Q - I get a syntax error inside the customisation part of the script. # # A - It's probably a problem with commas. There must be 1, and only one comma # # after each element in an array, though it can be skipped after the last one. # # An element can be any type of object. In this script you'll be dealing with: # # - strings: "string", # # - integers: 1, # # - arrays: [elements], # # Be aware that there's a nested array inside another array in this script so # # they'll all take commas too. # # Commas should be like this: [ [a, b, c], [e, f, g] ]... # #==============================================================================# # Compatibility: # #------------------------------------------------------------------------------# # New Methods: # # Scene_Title#setup_config # # - Would need to be aliased if another script created a setup_config method. # # # # Overwrites: # # Scene_Menu#create_command_window # # - Place above any scripts that edit the order of the main menu. # # Still mightn't be compatible though. # # # #==============================================================================# module SOV module MapSelection ####=============================#############==============================#### # CUSTOMISATION # ####========================================================================#### # Edit values below to customise values used in the script # ###===========================#############============================### # Setup the maps shown in the map selection screen: MAPS = [ ["Mission 1","M1", 20, 18, 63, 8, '[\C[18]Description\C[0]] \C[18]Location:\C[0] Anomaly Center \C[18]Time:\C[0] 11:15 PM \C[18]Target:\C[0] Mystery Assassin', false, false], ["Mission 2","bar", 1, 8, 5, 8, "Test", true, false] # Add arrays with the following format to create start locations: # [name, bitmap, map_id, x, y, dir, description, locked, hidden] # - name: Name displayed in the map selection window. # - bitmap: Image filename, from "Graphics/Pictures/". # - map_id: Map id to transfer to. # - x: x coordinate to transfer to. # - y: y coordinate to transfer to. # - dir: Direction the player faces after transfering # 2: down, 4: left, 6: right, 8: up # - Description: The map's description. # - Use \n to skip line, or actually skip to the next line. # - Use \N[n] for actor id n's name. # - Use \V[n] for variable n's value. # - Use \C[n] to change text to the corresponding colour. # - Use \I[n] to draw icon with index n. # - Use \U to underline text up to the next \U. # Colours are obtained from the blocks of colour on the bottom # right of the Graphics/System/Window. # n must be between 0 and 31. # # All descriptions must be between apostrophe's '' rather than quotes "". # To use an apostrophe in the description put a backslash before it: #'Paul\'s \C[14]house' # Alternatively you can use double quotes, but also two backslashes instead of # one before special characters: # "Paul's \\C[14]house" # - locked: If true name and image appear greyed out and unselectable. # Change with a script call. # - hidden: If true map isn't included in list. Change with a script call. # Also don't forget the comma at the end of each array element! # See the demo for examples. # <-- Add here ] # Don't delete this! # Set to false to disable map selection from title. TITLE_COMMAND = false # If true start selection window can be opened from the main menu. MENU_COMMAND = false # Text for the menu command that opens the map selection window. MENU_CHANGE = 'Select Mission' # The position of this command in the menu. # O is the top position. MENU_INDEX = 5 # If true the player can return to their last map from the quit submenu. RETURN_MAP = true # Text for the menu command that returns to previous map. # Appears in the quit submenu. MENU_RETURN = 'Cancel Mission Select' # If true descriptions are hidden when maps are unavailable. HIDE_DESCRIPTION = true # Text displayed when the map is locked. LOCKED_TEXT = '- Mission Unavailable -' # Text displayed if the map to transfer to is the current map. CURRENT_TEXT = '- Current Mission -' # Size of the font used for map selection names. FONT_SIZE_SELECTION = 18 # Size of the font used in the description. FONT_SIZE_DESCRIPTION = 18 # Font size used for displaying current map state(locked? ,etc) across its bitmap. FONT_SIZE_STATE = 18 ####=============================#############==============================#### # END CUSTOMISATION # ####------------------------------------------------------------------------#### # Unless you can script you shouldn't edit beyond this point # ###===========================#############============================### end end #============================================================================== # * Vocab #============================================================================== module Vocab # SOV - StartSelection ChangeMap = SOV::MapSelection::MENU_CHANGE ReturnMap = SOV::MapSelection::MENU_RETURN MapLocked = SOV::MapSelection::LOCKED_TEXT CurrentMap = SOV::MapSelection::CURRENT_TEXT end #============================================================================== # IMPORT #============================================================================== $imported = {} if $imported == nil $imported["MapSelection"] = true #============================================================================== # * Game_Temp #============================================================================== class Game_Temp #-------------------------------------------------------------------------- # * Public Instance Variables #-------------------------------------------------------------------------- attr_accessor :selection_from_title # True if map selection from title attr_accessor :selection_from_event # True if map selection from event #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- alias :sov_ms_initialize :initialize def initialize sov_ms_initialize @selection_from_title = false @selection_from_event = false end end #============================================================================== # ** Game_System #============================================================================== class Game_System #-------------------------------------------------------------------------- # * Public Instance Variables #-------------------------------------------------------------------------- attr_accessor :map_selection_disabled # Map selection availability attr_accessor :map_return_disabled # Map return availability attr_accessor :last_map # Last map transfered to attr_accessor :last_pos # Array [x, y] of last coordinates #-------------------------------------------------------------------------- # Object Initialization #-------------------------------------------------------------------------- alias :sov_ms_initialize :initialize def initialize sov_ms_initialize @map_selection_disabled = false @map_return_disabled = false @last_map = nil @last_pos = [] end end #============================================================================== # ** Game_Interpreter #============================================================================== class Game_Interpreter #-------------------------------------------------------------------------- # * Call Map Selection #-------------------------------------------------------------------------- def open_selection_screen $game_temp.selection_from_event = true $game_temp.selection_from_title = false $scene = Scene_MapSelection.new end #-------------------------------------------------------------------------- # * Enable Map Selection #-------------------------------------------------------------------------- def enable_map_selection $game_system.map_selection_disabled = false end #-------------------------------------------------------------------------- # * Disable Map Selection #-------------------------------------------------------------------------- def disable_map_selection $game_system.map_selection_disabled = true end #-------------------------------------------------------------------------- # * Enable Map Return #-------------------------------------------------------------------------- def enable_map_return $game_system.map_return_disabled = false end #-------------------------------------------------------------------------- # * Disable Map Return #-------------------------------------------------------------------------- def disable_map_return $game_system.map_return_disabled = true $game_system.last_map = nil end #-------------------------------------------------------------------------- # * Switch Locked(name) # name : map transfer's name #-------------------------------------------------------------------------- def switch_locked_name(name) for i in 0...SOV::MapSelection::MAPS.size check = name.gsub(/\n/i) {""} if $game_map_selection[i].name == check $game_map_selection[i].switch_lock break end end end #-------------------------------------------------------------------------- # * Switch Locked(index) # index : map transfer's index #-------------------------------------------------------------------------- def switch_locked_index(index) $game_map_selection[index].switch_lock end #-------------------------------------------------------------------------- # * Switch Hidden(name) # name : map transfer's name #-------------------------------------------------------------------------- def switch_hidden_name(name) for i in 0...SOV::MapSelection::MAPS.size check = name.gsub(/\n/i) {""} if $game_map_selection[i].name == check $game_map_selection[i].switch_hidden break end end end #-------------------------------------------------------------------------- # * Switch Hidden(index) # index : map transfer's index #-------------------------------------------------------------------------- def switch_hidden_index(index) $game_map_selection[index].switch_hidden end end #============================================================================== # ** Game_StartPoint #============================================================================== class Game_MapTransfer #-------------------------------------------------------------------------- # * Public Instance Variables #-------------------------------------------------------------------------- attr_reader :name # string for map name attr_reader :bitmap_filename # bitmap assossiated with map name attr_reader :map_id # Map starting position attr_reader :transfer_x # x starting position attr_reader :transfer_y # y starting position attr_reader :transfer_dir # direction to face after starting attr_reader :description # Text displayed in description window attr_accessor :locked # Flag for map transfer locked attr_accessor :hidden # Flag for map transfer hidden #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(name, bitmap, map_id, transfer_x, transfer_y, direction, description, locked, hidden) @name = name @bitmap_filename = bitmap @map_id = map_id @transfer_x = transfer_x @transfer_y = transfer_y @transfer_dir = direction @description = description @locked = locked @hidden = hidden end #-------------------------------------------------------------------------- # * Return true if the current map is the map_transfer #-------------------------------------------------------------------------- def current_map? return self.map_id == $game_map.map_id end #-------------------------------------------------------------------------- # * Negate locked instance #-------------------------------------------------------------------------- def switch_lock @locked ? @locked = false : @locked = true end #-------------------------------------------------------------------------- # * Negate hidden instance #-------------------------------------------------------------------------- def switch_hidden @hidden ? @hidden = false : @hidden = true end end #============================================================================== # * Game_MapSelection #============================================================================== class Game_MapSelection #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize return @map_transfers = [] end #-------------------------------------------------------------------------- # * Get Map Transfer # map_transfer_id : map transfer ID #-------------------------------------------------------------------------- def [](map_transfer_id) if @map_transfers[map_transfer_id] == nil return false else return @map_transfers[map_transfer_id] end end #-------------------------------------------------------------------------- # * Get Locations #-------------------------------------------------------------------------- def map_transfers return @map_transfers end #-------------------------------------------------------------------------- # * Setup #-------------------------------------------------------------------------- def setup @map_transfers = [] for i in 0...SOV::MapSelection::MAPS.size map_transfer = Game_MapTransfer.new(*SOV::MapSelection::MAPS[i]) @map_transfers.push(map_transfer.clone) end end end #============================================================================== # ** Sprite_MapBitmap #============================================================================== class Sprite_MapBitmap < Sprite #-------------------------------------------------------------------------- # * Object Initialization # x : x coord # y : y coord # map_transfer : map transfer #-------------------------------------------------------------------------- def initialize(x, y, map_transfer) super(Viewport.new(x, y, 240, 176)) new_sprite(map_transfer) end #-------------------------------------------------------------------------- # * New Sprite #-------------------------------------------------------------------------- def new_sprite(map_transfer) self.bitmap.dispose unless self.bitmap == nil unless map_transfer.bitmap_filename == (nil or false or "") self.bitmap = Cache.picture("#{map_transfer.bitmap_filename}") self.opacity = ((map_transfer.locked or map_transfer.current_map?) ? 96 : 255) else self.bitmap = Bitmap.new(240, 176) bitmap.fill_rect(bitmap.rect, Color.new(128, 128, 128)) end self.zoom_x = 240.00 / bitmap.width - (3.000 / 240) self.zoom_y = 176.00 / bitmap.height - (3.000 / 176) end end #============================================================================== # ** Window_Border #============================================================================== class Window_Border < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(x, y) super(x , y, 240, 176) self.back_opacity = 0 self.z = 150 end #-------------------------------------------------------------------------- # * Draw State # map_transfer : map_transfer #-------------------------------------------------------------------------- def draw_state(map_transfer) contents.clear txt = map_transfer.locked ? Vocab::MapLocked : map_transfer.current_map? ? Vocab::CurrentMap : nil unless txt == nil contents.font.size = SOV::MapSelection::FONT_SIZE_STATE tx = self.contents.text_size(txt).width ty = self.contents.text_size(txt).height x = (240 - tx) / 2 - WLH y = (176 - ty - WLH) / 2 contents.font.color.alpha = ((map_transfer.locked or map_transfer.current_map?) ? 128 : 255) contents.draw_text(x, y, tx, ty, txt, 1) end end end #============================================================================== # ** Window_MapSelection #============================================================================== class Window_MapSelection < Window_Selectable #-------------------------------------------------------------------------- # * Object Initialization # x : window X coordinate # y : window Y corrdinate #-------------------------------------------------------------------------- def initialize(x, y) super(x, y, 240, 240) @column_max = 1 self.index = 0 refresh end #-------------------------------------------------------------------------- # * Get Map Transfer #-------------------------------------------------------------------------- def map_transfer return @data[self.index] end #-------------------------------------------------------------------------- # * Whether or not to include(hidden?) # map_transfer : map transfer #-------------------------------------------------------------------------- def hidden?(map_transfer) return false if map_transfer == nil return false unless map_transfer.hidden return true end #-------------------------------------------------------------------------- # * Whether or not to display semi transparent(locked?) # map_transfer : map transfer #-------------------------------------------------------------------------- def locked?(map_transfer) return map_transfer.locked end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh @data = [] @story_maps = [] for map_transfer in $game_map_selection.map_transfers next if hidden?(map_transfer) @data.push(map_transfer) end @data.push(nil) if hidden?(nil) @item_max = @data.size create_contents contents.font.color = normal_color for i in 0...@item_max draw_map_transfer(i) end end #-------------------------------------------------------------------------- # * Draw Map Transfers #-------------------------------------------------------------------------- def draw_map_transfer(map_transfer_id) rect = item_rect(map_transfer_id) contents.clear_rect(rect) contents.font.size = SOV::MapSelection::FONT_SIZE_SELECTION map_transfer = @data[map_transfer_id] contents.font.color.alpha = (locked?(map_transfer) or map_transfer.current_map?) ? 128 : 255 if map_transfer != nil rect.width -= 4 contents.draw_text(rect.x + 4, rect.y, 172, WLH, map_transfer.name) end end end #============================================================================== # ** Window_MapDescription #============================================================================== class Window_MapDescription < Window_Base #-------------------------------------------------------------------------- # * Constants #-------------------------------------------------------------------------- FONT_SIZE = SOV::MapSelection::FONT_SIZE_DESCRIPTION WH = FONT_SIZE + 2 #-------------------------------------------------------------------------- # * Object Initialization # x : window X coordinate # y : window Y corrdinate #-------------------------------------------------------------------------- def initialize(x, y) super(x, y, 304, 416) @text = nil @description_x = 0 @description_y = 0 @line_count = 0 setup end #-------------------------------------------------------------------------- # * Setup #-------------------------------------------------------------------------- def setup contents.font.size = FONT_SIZE @max_line = contents.height / WH end #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update update_description if @text != nil end #-------------------------------------------------------------------------- # * New Description #-------------------------------------------------------------------------- def new_description(map_transfer) if SOV::MapSelection::HIDE_DESCRIPTION and map_transfer.locked @text = "" return end @text = sub_special_characters(map_transfer.description.clone) end #-------------------------------------------------------------------------- # * Sub Special Characters # line : string #-------------------------------------------------------------------------- def sub_special_characters(line) line.gsub!(/\n/i) {"\x00"} # Next line line.gsub!(/\\V\[([0-9]+)\]/i) {$game_variables[$1.to_i]} # Variable line.gsub!(/\\N\[([0-9]+)\]/i) {$game_actors[$1.to_i].name} # Actor line.gsub!(/\\C\[([0-9]+)\]/i) {"\x01[#{$1}]"} # colour line.gsub!(/\\I\[([0-9]+)\]/i) {"\x02[#{$1}]"} # Icon line.gsub!(/\\U/i) {"\x03"} # Underline return line end #-------------------------------------------------------------------------- # * Update Description #-------------------------------------------------------------------------- def update_description contents.clear loop do c = @text.slice!(/./m) case c when nil break when "\x00" @line_count += 1 break if @line_count > @max_line @description_y += WH @description_x = 0 when "\x01" @text.sub!(/\[([0-9]+)\]/, "") contents.font.color = text_color($1.to_i) when "\x02" @text.sub!(/\[([0-9]+)\]/, "") draw_icon($1.to_i, @description_x, @description_y - 12 + WH / 2) @description_x += 24 when "\x03" @underline ? @underline = false : @underline = true else contents.draw_text(@description_x, @description_y, 40, WH, c) contents.draw_text(@description_x, @description_y, 40, WH, "_") if @underline c_width = contents.text_size(c).width @description_x += c_width end end reset_description end #-------------------------------------------------------------------------- # * Reset Description #-------------------------------------------------------------------------- def reset_description @text = nil @description_x = 0 @description_y = 0 @line_count = 0 @underline = false contents.font.color = normal_color end end #============================================================================== # ** Scene_Title #============================================================================== class Scene_Title < Scene_Base #-------------------------------------------------------------------------- # * Start processing #-------------------------------------------------------------------------- alias :sov_ss_start :start def start sov_ss_start setup_config end #-------------------------------------------------------------------------- # * Setup Values from Customisation Module #-------------------------------------------------------------------------- def setup_config $game_map_selection.setup end #-------------------------------------------------------------------------- # * Create Game Objects #-------------------------------------------------------------------------- alias :sov_ms_create_game_objects :create_game_objects def create_game_objects sov_ms_create_game_objects $game_map_selection = Game_MapSelection.new end #-------------------------------------------------------------------------- # * Command: New Game #-------------------------------------------------------------------------- alias :sov_ms_command_new_game :command_new_game def command_new_game if not SOV::MapSelection::TITLE_COMMAND sov_ms_command_new_game return end confirm_map_existence Sound.play_decision close_command_window $game_temp.selection_from_title = true $scene = Scene_MapSelection.new end #-------------------------------------------------------------------------- # * Check Player Start Location Existence #-------------------------------------------------------------------------- def confirm_map_existence if SOV::MapSelection::MAPS.size == 0 print "No start locations set. Start locations are set up within the SOV - StartSelection script." exit end end end #============================================================================== # ** Scene_Main #============================================================================== class Scene_Menu < Scene_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- alias :sov_ms_initialize :initialize def initialize(menu_index = 0, change = true) sov_ms_initialize(menu_index) @command_index = SOV::MapSelection::MENU_INDEX if SOV::MapSelection::MENU_COMMAND @menu_index += 1 if @menu_index >= @command_index and change end end #-------------------------------------------------------------------------- # * Create Command Window (OVERWRITTEN) #-------------------------------------------------------------------------- def create_command_window s1 = Vocab::item s2 = Vocab::skill s3 = Vocab::equip s4 = Vocab::status s5 = Vocab::save s6 = Vocab::game_end sn = Vocab::ChangeMap commands = [s1, s2, s3, s4 , s5, s6] commands.insert(@command_index, sn) if SOV::MapSelection::MENU_COMMAND @command_window = Window_Command.new(160, commands) @command_window.index = @menu_index if $game_party.members.size == 0 @command_window.draw_item(commands.index(s1), false) @command_window.draw_item(commands.index(s2), false) @command_window.draw_item(commands.index(s3), false) @command_window.draw_item(commands.index(s4), false) end if $game_system.save_disabled @command_window.draw_item(commands.index(s5), false) end if $game_system.map_selection_disabled and SOV::MapSelection::MENU_COMMAND @command_window.draw_item(commands.index(sn), false) end end #-------------------------------------------------------------------------- # * Update Command Selection #-------------------------------------------------------------------------- alias :sov_ms_update_command_selection :update_command_selection def update_command_selection if SOV::MapSelection::MENU_COMMAND if Input.trigger?(Input::C) && @command_window.index == @command_index if $game_system.map_selection_disabled Sound.play_buzzer return end Sound.play_decision $game_temp.selection_from_title = false $game_temp.selection_from_event = false $scene = Scene_MapSelection.new return end if Input.trigger?(Input::C) && @command_window.index > @command_index @command_window.index = @command_window.index - 1 cursor_change ||= true end end sov_ms_update_command_selection @command_window.index = @command_window.index + 1 if cursor_change end end #============================================================================== # ** Scene_End #============================================================================== class Scene_End #-------------------------------------------------------------------------- # * Create Command Window #-------------------------------------------------------------------------- alias :sov_ms_create_command_window :create_command_window def create_command_window sov_ms_create_command_window @command_window.commands[2] = Vocab::ReturnMap @command_window.draw_item(2, $game_system.last_map == nil ? false : true) end #-------------------------------------------------------------------------- # * Command: Cancel #-------------------------------------------------------------------------- alias :sov_ms_command_cancel :command_cancel def command_cancel if SOV::MapSelection::RETURN_MAP if $game_system.last_map == nil Sound.play_buzzer return end $scene = Scene_Map.new Sound.play_decision RPG::BGM.fade(1500) $game_map.setup($game_system.last_map) $game_player.moveto(*$game_system.last_pos) Graphics.fadeout(60) Graphics.wait(40) Graphics.frame_count = 0 RPG::BGM.stop $game_map.autoplay $game_system.last_map = nil else sov_ms_command_cancel end end end #============================================================================== # ** Scene_File #============================================================================== class Scene_File #-------------------------------------------------------------------------- # * Write Save Data # file : write file object (opened) #-------------------------------------------------------------------------- alias :sov_ms_write_save_data :write_save_data def write_save_data(file) sov_ms_write_save_data(file) Marshal.dump($game_map_selection, file) end #-------------------------------------------------------------------------- # * Read Save Data # file : file object for reading (opened) #-------------------------------------------------------------------------- alias :sov_ms_read_save_data :read_save_data def read_save_data(file) sov_ms_read_save_data(file) $game_map_selection = Marshal.load(file) end end #============================================================================== # ** Scene_MapSelection #============================================================================== class Scene_MapSelection < Scene_Base #-------------------------------------------------------------------------- # * Start processing #-------------------------------------------------------------------------- def start super @selection_window = Window_MapSelection.new(0, 176) @sprite_border = Window_Border.new(0, 0) @map_sprite = Sprite_MapBitmap.new(2, 2, @selection_window.map_transfer) @description_window = Window_MapDescription.new(240, 0) end #-------------------------------------------------------------------------- # * Termination Processing #-------------------------------------------------------------------------- def terminate super $game_map.refresh @selection_window.dispose @description_window.dispose @map_sprite.dispose @sprite_border.dispose end #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update super @selection_window.update @description_window.update update_map_transfer_selection update_new_selection end #-------------------------------------------------------------------------- # * Update Start Point Selection #-------------------------------------------------------------------------- def update_map_transfer_selection if Input.trigger?(Input::B) Sound.play_cancel return_scene elsif Input.trigger?(Input::C) map_transfer = @selection_window.map_transfer if @map_transfer.locked or @map_transfer.current_map? Sound.play_buzzer return end Sound.play_decision if $game_temp.selection_from_title transfer_to_map_title(@map_transfer) else transfer_to_map(@map_transfer) end end end #-------------------------------------------------------------------------- # * Update when new menu index #-------------------------------------------------------------------------- def update_new_selection if @selection_window.map_transfer != @last_map_transfer @map_transfer = @selection_window.map_transfer @description_window.new_description(@map_transfer) @map_sprite.new_sprite(@map_transfer) @sprite_border.draw_state(@map_transfer) end @last_map_transfer = @selection_window.map_transfer end #-------------------------------------------------------------------------- # * Return to Original Scene #-------------------------------------------------------------------------- def return_scene if $game_temp.selection_from_title $scene = Scene_Title.new elsif $game_temp.selection_from_event $scene = Scene_Map.new else $scene = Scene_Map.new end end #-------------------------------------------------------------------------- # * Determine Map # map_transfer : map transfer #-------------------------------------------------------------------------- def transfer_to_map_title(map_transfer) Sound.play_decision $game_party.setup_starting_members $game_map.setup(map_transfer.map_id) $game_player.moveto(map_transfer.transfer_x, map_transfer.transfer_y) $game_player.set_direction(map_transfer.transfer_dir) $game_player.refresh $scene = Scene_Map.new RPG::BGM.fade(1500) Graphics.fadeout(60) Graphics.wait(40) Graphics.frame_count = 0 RPG::BGM.stop $game_map.autoplay end #-------------------------------------------------------------------------- # * Transfer to Map # map_transfer : map transfer #-------------------------------------------------------------------------- def transfer_to_map(map_transfer) $game_system.last_pos = [$game_player.x, $game_player.y] if $game_system.map_return_disabled $game_system.last_map = nil else $game_system.last_map = $game_map.map_id end $scene = Scene_Map.new RPG::BGM.fade(1500) $game_map.setup(map_transfer.map_id) $game_player.moveto(map_transfer.transfer_x, map_transfer.transfer_y) $game_player.set_direction(map_transfer.transfer_dir) Graphics.fadeout(60) Graphics.wait(40) Graphics.frame_count = 0 RPG::BGM.stop $game_map.autoplay end end #=================\__________________________________________/=================# #==============================#________________#==============================# #/ / / / / / / / / / / / / / / / \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \# #| | SuperOverlord | |# #\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \________________/ / / / / / / / / / / / / / / /# #==============================#________________#==============================# #===============/ Share this post Link to post Share on other sites
Broken Messiah 20 Report post Posted April 21, 2011 I have that exact same script, but I didnt think to use it that way. :sweatdrop: Share this post Link to post Share on other sites
kellessdee 48 Report post Posted April 22, 2011 Do you still need a new script or does this one work the way you would like it? Share this post Link to post Share on other sites
Broken Messiah 20 Report post Posted April 27, 2011 It gets the job done, but it lacks many of the features I'd like: Party select upon accepting a mission ... figured there would be more lol Its no big thing, I could just have a party select script added Share this post Link to post Share on other sites
kellessdee 48 Report post Posted April 27, 2011 Hmm. Well I could probably get something done to your necessity, my only issue at the moment is apparently my rmvx trial period has ran out XD so I can't really test the script...unless someone were to send me a new (fresh) rmvx project, then I could easily load the scripts into rpg maker xp's editor, do whatever, throw it into the rmvx data files then just run the game.exe to test it. Thats not violating any ToS is it? :D Share this post Link to post Share on other sites
Broken Messiah 20 Report post Posted April 27, 2011 There are alternatives ... :dragoninsane: but I guess that would work, though wouldnt it be easier to use something like Programmers Notepad which is like a standalone of the scripting tool on steroids. The problem is though, how would you be able to incorperate the new script into the scripts.rvdata? Share this post Link to post Share on other sites
kellessdee 48 Report post Posted April 27, 2011 Well I am a little sneaky and get curious and try to mess with things...I have realized that .rxdata & .rvdata aren't real extension types at all. I have managed to get all the rmvx scripts into rmxp (they don't actually work of course) by simply renaming "Scripts.rvdata" to "Scripts.rxdata" so I can do that, make modifications, flip it back to .rvdata, and the game will load it all the same. And really, doing the scripts themselves i could easily write in notepad as well (of course no syntax highlighting...) but the only thing I would dislike is not being able to test the script. And merely hoping it works. Though, thanks for that link to programmers notepad!!!! I have notepad++ which is alright, but that looks like 999999x better!!! :D Share this post Link to post Share on other sites