| ¿Quién está en línea? | En total hay 21 usuarios en línea: 2 Registrados, 0 Ocultos y 19 Invitados :: 1 Motor de búsqueda Akito_squall, ShooterLa mayor cantidad de usuarios en línea fue 179 el Mar Ago 30, 2011 1:06 pm. |
| Flag Counter |  |
| | | Ayuda con partida guardada | |
| | Autor | Mensaje |
|---|
chronoMx Aprendiz

Cantidad de envíos: 5 Miembro desde: 26/01/2012 Maker: 
 | Tema: Ayuda con partida guardada Sáb Mayo 26, 2012 5:45 pm | |
| Hola amigos de maker palace este es mi primer post y esque la verdad busque mucho y no pude solucionar mi problema, haber si alguien me puede hechar un guante quiero que mi proyecto tenga un solo slot para guardar, y no encuentro la manera para que esto sea posible, alguien me puede ayudar.. P.D uso el MOG de guardado |
|  | | SagahonArturo Moderador


Cantidad de envíos: 1446 Miembro desde: 19/12/2010 Edad: 18 Sexo: 
Maker: 
Logros MP:

 
 | Tema: Re: Ayuda con partida guardada Sáb Mayo 26, 2012 6:32 pm | |
| Bueno sería bueno que agregaras estos datos para poder ser ayudado: Sistema Maker que usas (XP, VX, VXACE)., el script en el cual tienes problemas o requieres una modificación. Entre corchetes la sintaxi de CODE:”[code.][/code.]” Sin puntos. De otra manera será muy difícil que alguien te de soporte. Nos vemos. |
|  | | Mur-mai-der Diamante


Cantidad de envíos: 1146 Miembro desde: 25/11/2010 Edad: 16 Localización: En Nicunihué Sexo: 
Maker: 
Logros MP:

 | Tema: Re: Ayuda con partida guardada Dom Mayo 27, 2012 4:58 am | |
| Ademas del Sagahon, no hay users épicamente activos que sepan Ruby. Mmm creo que tu respuesta no llegará en alog de tiempo. Pero sé paciente. |
|  | | SagahonArturo Moderador


Cantidad de envíos: 1446 Miembro desde: 19/12/2010 Edad: 18 Sexo: 
Maker: 
Logros MP:

 
 | |  | | chronoMx Aprendiz

Cantidad de envíos: 5 Miembro desde: 26/01/2012 Maker: 
 | Tema: Re: Ayuda con partida guardada Lun Mayo 28, 2012 4:31 pm | |
| disculpa por mi descuido, uso el RPGMAKER XP y anexe el script de mog scene file [spoiler] | Código: | #_______________________________________________________________________________ # MOG Scene File Ayumi V1.0 #_______________________________________________________________________________ # By Moghunter #_______________________________________________________________________________ if true # True = Enable / False = Disable (Script) module MOG #Transition Time. MSVT = 30 #Transition Type. MSVTT = "006-Stripe02" end $mogscript = {} if $mogscript == nil $mogscript["menu_ayumi"] = true ############### # Window_Base # ############### class Window_Base < Window def drw_win_file(x,y) dwf = RPG::Cache.picture("Win_File") cw = dwf.width ch = dwf.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, dwf, src_rect) end def nada face = RPG::Cache.picture("") end def draw_heroface3(actor,x,y) face = RPG::Cache.picture(actor.name + "_fc3") rescue nada cw = face.width ch = face.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, face, src_rect) end def draw_actor_level6(actor, x, y) self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(x + 1, y + 1, 32, 32, "Lv") self.contents.font.color = system_color self.contents.draw_text(x, y, 32, 32, "Lv") self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(x + 17, y + 1, 24, 32, actor.level.to_s, 2) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(x + 16, y, 24, 32, actor.level.to_s, 2) end def draw_actor_name6(actor, x, y) self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(x + 1, y + 1, 100, 32, actor.name,1) self.contents.font.color = normal_color self.contents.draw_text(x, y, 100, 32, actor.name,1) end end ############ # Game_Map # ############ class Game_Map def map_name @mapinfo = load_data("Data/MapInfos.rxdata") if @mapinfo == nil return @mapinfo[@map_id].name end end ################### # Window_SaveFile # ################### class Window_SaveFile < Window_Base attr_reader :filename attr_reader :selected def initialize(file_index, filename) super(0, 64 + file_index * 138, 640, 240) self.contents = Bitmap.new(width - 32, height - 32) self.opacity = 0 @file_index = file_index @filename = "Save#{@file_index + 1}.rxdata" @time_stamp = Time.at(0) @file_exist = FileTest.exist?(@filename) if @file_exist file = File.open(@filename, "r") @time_stamp = file.mtime @characters = Marshal.load(file) @frame_count = Marshal.load(file) @game_system = Marshal.load(file) @game_switches = Marshal.load(file) @game_variables = Marshal.load(file) @game_self_switches = Marshal.load(file) @game_screen = Marshal.load(file) @game_actors = Marshal.load(file) @game_party = Marshal.load(file) @game_troop = Marshal.load(file) @game_map = Marshal.load(file) @total_sec = @frame_count / Graphics.frame_rate file.close end @wiref = 0 refresh @selected = false end def refresh self.contents.clear self.contents.font.name = "Georgia" drw_win_file(0,190) name = "#{@file_index + 1}" self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(161, 41, 600, 32, name) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(160, 40, 600, 32, name) @name_width = contents.text_size(name).width if @file_exist for i in 0...@characters.size bitmap = RPG::Cache.character(@characters[i][0], @characters[i][1]) cw = bitmap.rect.width / 4 ch = bitmap.rect.height / 4 src_rect = Rect.new(cw * @wiref + 1 , 0, cw, ch) x = 300 - @characters.size + i * 64 - cw / 4 self.contents.blt(x - 10, 150 - ch, bitmap, src_rect) x = 116 actors = @game_party.actors for i in 0...[actors.size, 4].min x = i * 60 actor = actors[i] self.contents.font.size = 20 draw_actor_level6(actor, x + 280, 140) actor = actors[0] draw_heroface3(actor,160,180) draw_actor_name6(actor, 160, 155) self.contents.font.size = 22 end end hour = @total_sec / 60 / 60 min = @total_sec / 60 % 60 sec = @total_sec % 60 time_string = sprintf("%02d:%02d:%02d", hour, min, sec) self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(5, 41, 450, 32, time_string, 2) self.contents.draw_text(41 , 141, 120 , 32, @game_map.map_name.to_s) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(40 , 140, 120 , 32, @game_map.map_name.to_s) self.contents.draw_text(4, 40, 450, 32, time_string, 2) end end def selected=(selected) @selected = selected end end ############## # Scene_File # ############## class Scene_File def initialize(help_text) @help_text = help_text end def main @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture("MN_BK") @mnback.z = 1 @mnlay = Sprite.new @mnlay.bitmap = RPG::Cache.picture("Lay_File.PNG") @mnlay.z = 2 @help_window = Window_Help.new @help_window.set_text(@help_text) @help_window.opacity = 0 @savefile_windows = [] for i in 0..2 @savefile_windows.push(Window_SaveFile.new(i, make_filename(i))) end @savefile_windows[0] @file_index = $game_temp.last_file_index @savefile_windows[@file_index].selected = true @savefile_windows[0].y = 40 @savefile_windows[1].y= 140 @savefile_windows[2].y= 240 @win_move_time = 0 @win_move = 0 @win_dire = 0 @win_opac = 255 @win1_y = 0 @win2_y = 0 @win3_y = 0 Graphics.transition(MOG::MSVT, "Graphics/Transitions/" + MOG::MSVTT) loop do Graphics.update Input.update update if $scene != self break end end for i in 0..50 @mnback.ox += 1 @savefile_windows[0].x += 10 @savefile_windows[1].x -= 10 @savefile_windows[2].x += 10 for i in @savefile_windows i.contents_opacity -= 5 end Graphics.update end Graphics.freeze @help_window.dispose @mnback.dispose @mnlay.dispose for i in @savefile_windows i.dispose end end def update @mnback.ox += 1 @win_opac += 3 @win_move_time += 1 if @win_opac > 254 @win_opac = 150 end if @win_move_time > 60 @win_dire += 1 @win_move_time = 0 end if @win_dire > 1 @win_dire = 0 end if @win_dire == 0 @win_move += 1 else @win_move -= 1 end if @file_index == 0 @savefile_windows[0].z = 2 @savefile_windows[1].z = 1 @savefile_windows[2].z = 0 @savefile_windows[0].x = @win_move @savefile_windows[1].x = 0 @savefile_windows[1].x= 0 @savefile_windows[2].x = 0 @savefile_windows[0].contents_opacity = @win_opac @savefile_windows[1].contents_opacity = 130 @savefile_windows[2].contents_opacity = 130 elsif @file_index == 1 @savefile_windows[0].z = 1 @savefile_windows[1].z = 2 @savefile_windows[2].z = 1 @savefile_windows[0].x = 0 @savefile_windows[1].x = @win_move @savefile_windows[2].x = 0 @savefile_windows[0].contents_opacity = 130 @savefile_windows[1].contents_opacity = @win_opac @savefile_windows[2].contents_opacity = 130 else @savefile_windows[0].z = 0 @savefile_windows[1].z = 1 @savefile_windows[2].z = 2 @savefile_windows[0].x = 0 @savefile_windows[1].x = 0 @savefile_windows[2].x = @win_move @savefile_windows[0].contents_opacity = 130 @savefile_windows[1].contents_opacity = 130 @savefile_windows[2].contents_opacity = @win_opac end @help_window.update for i in @savefile_windows i.update end if Input.trigger?(Input::C) on_decision(make_filename(@file_index)) $game_temp.last_file_index = @file_index return end if Input.trigger?(Input::B) on_cancel return end if Input.repeat?(Input::DOWN) if Input.trigger?(Input::DOWN) or @file_index < 3 $game_system.se_play($data_system.cursor_se) @savefile_windows[@file_index].selected = false @file_index = (@file_index + 1) % 3 @savefile_windows[@file_index].selected = true return end end if Input.repeat?(Input::UP) if Input.trigger?(Input::UP) or @file_index > 0 $game_system.se_play($data_system.cursor_se) @savefile_windows[@file_index].selected = false @file_index = (@file_index - 1) % 3 @savefile_windows[@file_index].selected = true return end end end def make_filename(file_index) return "Save#{file_index + 1}.rxdata" end end end
| [/spoilerl]
espero sea posible se los agradecere mucho |
|  | | SagahonArturo Moderador


Cantidad de envíos: 1446 Miembro desde: 19/12/2010 Edad: 18 Sexo: 
Maker: 
Logros MP:

 
 | Tema: Re: Ayuda con partida guardada Lun Mayo 28, 2012 5:10 pm | |
| Ehhehe… tendrás las imágenes para el menú? O_O para poder ver el detalle en los gráficos?, o donde los bajo? Nos vemos. |
|  | | Darkshadow Diamante


Cantidad de envíos: 644 Miembro desde: 05/01/2011 Edad: 17 Localización: Lorqui / Murcia Sexo: 
Maker: 
Logros MP:
  
 | Tema: Re: Ayuda con partida guardada Mar Mayo 29, 2012 5:57 am | |
| yo puedo ayudar solo dime el numero de slot que ya vienen por defecto |
|  | | SagahonArturo Moderador


Cantidad de envíos: 1446 Miembro desde: 19/12/2010 Edad: 18 Sexo: 
Maker: 
Logros MP:

 
 | Tema: Re: Ayuda con partida guardada Mar Mayo 29, 2012 6:28 am | |
| Por lo que veo es un sistema de guardado de 3 slots. Pero creo que sería conveniente tener las imágenes para hacer pruebas de la modificación. Nos vemos. |
|  | | Darkshadow Diamante


Cantidad de envíos: 644 Miembro desde: 05/01/2011 Edad: 17 Localización: Lorqui / Murcia Sexo: 
Maker: 
Logros MP:
  
 | Tema: Re: Ayuda con partida guardada Mar Mayo 29, 2012 7:25 am | |
| ok creo que se lo que hay que cambiar ahora mismo no tengo el pc pero lo podre cojer dentro de 1 hora entonces lo intentare modificar y subirlo en demo |
|  | | Darkshadow Diamante


Cantidad de envíos: 644 Miembro desde: 05/01/2011 Edad: 17 Localización: Lorqui / Murcia Sexo: 
Maker: 
Logros MP:
  
 | Tema: Re: Ayuda con partida guardada Miér Mayo 30, 2012 4:38 am | |
| siento el doble post pero ya lo tienes listo | Código: | #============================================================================== # ** MOG Scene File Ayumi V1.2 # By Moghunter # http://www.atelier-rgss.com #------------------------------------------------------------------------------ # ** Reinvisioned version # # This variant has retooled the MOG module by adding more configurables for # the user. No longer are the graphics hardwired into the code but are now # able to be altered in the revised configuration serction. # # Also, a few redundant modules have been deleted for compatability with # other systems. Please note that this system 'does' rewrite the save file # structure, so systems that append to the save file may need to be edited # for use with this script. #==============================================================================
module MOG # BASIC MENU CONFIGURATION # File Graphics Used FILE_LAYOUT = "Layout-File" # File Menu Graphics FILE_BACKGROUND = "Back-Other" # Animated background graphic FILE_STATUS = "Status-File" # File Window Graphic FACE_LARGE = "_Fl" # Suffix for large face graphics # File Effects FILE_MOVE_FX = false # If savefile moves side-to-side FILE_OPACITY_FX = false # If savefile changes opacity # Menu FILE_FX = 0 # Back FX (0=Moving/ 1=Still/ 2=Map) FILE_TRAN_TIME = 20 # Transition Time FILE_TRAN_TYPE = "004-Blind04" # Transition Type (Name) # Font Used FILE_FONT = "Georgia" # Font used in file menu end
# Mogscript global $mogscript = {} if $mogscript == nil $mogscript["menu_ayumi"] = true
#============================================================================== # ** Game_Map #------------------------------------------------------------------------------ # This class handles the map. It includes scrolling and passable determining # functions. Refer to "$game_map" for the instance of this class. #==============================================================================
class Game_Map #-------------------------------------------------------------------------- # * Get Map Name #-------------------------------------------------------------------------- def map_name @mapinfo = load_data("Data/MapInfos.rxdata") if @mapinfo == nil return @mapinfo[@map_id].name end end
#============================================================================== # ** Window_Base #------------------------------------------------------------------------------ # This class is for all in-game windows. #==============================================================================
class Window_Base < Window #-------------------------------------------------------------------------- # * Draw File Window # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def drw_win_file(x, y) dwf = RPG::Cache.picture(MOG::FILE_STATUS) cw = dwf.width ch = dwf.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, dwf, src_rect) end #-------------------------------------------------------------------------- # * Draw Empty Face #-------------------------------------------------------------------------- def nada face = RPG::Cache.picture("") end #-------------------------------------------------------------------------- # * Draw Face #3 (Larger face) # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_heroface3(actor, x, y) face = RPG::Cache.picture(actor.name + MOG::FACE_LARGE) rescue nada cw = face.width ch = face.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, face, src_rect) end #-------------------------------------------------------------------------- # * Draw Actor Level #6 # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_actor_level6(actor, x, y) self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 1, y + 1, 32, 32, "Lv") self.contents.font.color = system_color self.contents.draw_text(x, y, 32, 32, "Lv") self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 17, y + 1, 24, 32, actor.level.to_s, 2) self.contents.font.color = Color.new(255, 255, 255, 255) self.contents.draw_text(x + 16, y, 24, 32, actor.level.to_s, 2) end #-------------------------------------------------------------------------- # * Draw Actor Name #6 # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_actor_name6(actor, x, y) self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 1, y + 1, 100, 32, actor.name, 1) self.contents.font.color = normal_color self.contents.draw_text(x, y, 100, 32, actor.name, 1) end end
#============================================================================== # ** Window_SaveFile #------------------------------------------------------------------------------ # This window displays save files on the save and load screens. #==============================================================================
class Window_SaveFile < Window_Base #-------------------------------------------------------------------------- # * Object Initialization # file_index : save file index (0-3) # filename : file name #-------------------------------------------------------------------------- def initialize(file_index, filename) super(0, 64 + file_index * 138, 640, 240) self.contents = Bitmap.new(width - 32, height - 32) self.opacity = 0 @file_index = file_index @filename = "Save#{@file_index + 1}.rxdata" @time_stamp = Time.at(0) @file_exist = FileTest.exist?(@filename) if @file_exist file = File.open(@filename, "r") @time_stamp = file.mtime @characters = Marshal.load(file) @frame_count = Marshal.load(file) @game_system = Marshal.load(file) @game_switches = Marshal.load(file) @game_variables = Marshal.load(file) @game_self_switches = Marshal.load(file) @game_screen = Marshal.load(file) @game_actors = Marshal.load(file) @game_party = Marshal.load(file) @game_troop = Marshal.load(file) @game_map = Marshal.load(file) @total_sec = @frame_count / Graphics.frame_rate file.close end @wiref = 0 refresh @selected = false end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh self.contents.clear self.contents.font.name = MOG::FILE_FONT drw_win_file(0,190) name = "#{@file_index + 1}" self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(161, 41, 600, 32, name) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(160, 40, 600, 32, name) @name_width = contents.text_size(name).width if @file_exist for i in 0...@characters.size bitmap = RPG::Cache.character(@characters[i][0], @characters[i][1]) cw = bitmap.rect.width / 4 ch = bitmap.rect.height / 4 src_rect = Rect.new(cw * @wiref + 1 , 0, cw, ch) x = 300 - @characters.size + i * 64 - cw / 4 self.contents.blt(x - 10, 150 - ch, bitmap, src_rect) x = 116 actors = @game_party.actors for i in 0...[actors.size, 4].min x = i * 60 actor = actors[i] self.contents.font.size = 20 draw_actor_level6(actor, x + 280, 140) actor = actors[0] draw_heroface3(actor,160,180) draw_actor_name6(actor, 160, 155) self.contents.font.size = 22 end end hour = @total_sec / 60 / 60 min = @total_sec / 60 % 60 sec = @total_sec % 60 time_string = sprintf("%02d:%02d:%02d", hour, min, sec) self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(5, 41, 450, 32, time_string, 2) self.contents.draw_text(41 , 141, 120 , 32, @game_map.map_name.to_s) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(40 , 140, 120 , 32, @game_map.map_name.to_s) self.contents.draw_text(4, 40, 450, 32, time_string, 2) end end #-------------------------------------------------------------------------- # * Set Selected # selected : new selected (true = selected, false = unselected) #-------------------------------------------------------------------------- def selected=(selected) @selected = selected end end
#============================================================================== # ** Scene_Save #------------------------------------------------------------------------------ # This class performs save screen processing. #==============================================================================
class Scene_Save < Scene_File #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- alias mog_init initialize def initialize mog_init $mog_scene_filesave_flag = 1 end end
#============================================================================== # ** Scene_File #------------------------------------------------------------------------------ # This is a superclass for the save screen and load screen. #==============================================================================
class Scene_File #-------------------------------------------------------------------------- # * Main Processing #-------------------------------------------------------------------------- def main if $mog_scene_filesave_flag != 1 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 else if MOG::FILE_FX == 0 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 elsif MOG::FILE_FX == 1 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 else @spriteset = Spriteset_Map.new end end @mnlay = Sprite.new @mnlay.bitmap = RPG::Cache.picture(MOG::FILE_LAYOUT) @mnlay.z = 2 @help_window = Window_Help.new @help_window.set_text(@help_text) @help_window.opacity = 0 @savefile_windows = [] @cursor_displace = 0 for i in 0..0 @savefile_windows.push(Window_SaveFile.new(i, make_filename(i))) end @savefile_windows[0] @file_index = $game_temp.last_file_index @savefile_windows[@file_index].selected = true @savefile_windows[0].y = 40 #@savefile_windows[1].y = 140 #@savefile_windows[2].y = 240 @win_move_time = 0 @win_move = 0 @win_dire = 0 @win_opac = 255 @win1_y = 0 @win2_y = 0 @win3_y = 0 unless MOG::FILE_FX == 2 Graphics.transition(MOG::FILE_TRAN_TIME, "Graphics/Transitions/" + MOG::FILE_TRAN_TYPE) else Graphics.transition end loop do Graphics.update Input.update update if $scene != self break end end for i in 0..50 @mnback.ox += 1 if MOG::FILE_FX == 0 @savefile_windows[0].x += 10 for i in @savefile_windows i.contents_opacity -= 5 end Graphics.update end Graphics.freeze @help_window.dispose @mnback.dispose if MOG::FILE_FX == 0 @mnback.dispose if MOG::FILE_FX == 1 @mnback.dispose if MOG::FILE_FX == 2 && $mog_scene_filesave_flag != 1 @spriteset.dispose if MOG::FILE_FX == 2 && $mog_scene_filesave_flag == 1 $mog_scene_filesave_flag = 0 @mnlay.dispose for i in @savefile_windows ; i.dispose ; end end #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update @mnback.ox += 1 if MOG::FILE_FX == 0 if MOG::FILE_OPACITY_FX @win_opac += 3 @win_opac = 150 if @win_opac > 254 else @win_opac = 255 end @win_move_time += 1 if @win_move_time > 60 @win_dire += 1 @win_move_time = 0 end @win_dire = 0 if @win_dire > 1 if @win_dire == 0 @win_move += 1 else @win_move -= 1 end # Update File Windows update_window_z update_moving_window if MOG::FILE_MOVE_FX update_window_opacity @help_window.update for i in @savefile_windows ; i.update ; end if Input.trigger?(Input::C) on_decision(make_filename(@file_index)) $game_temp.last_file_index = @file_index return end if Input.trigger?(Input::B) on_cancel return end end #-------------------------------------------------------------------------- # * Frame Update (Reposition File Window) #-------------------------------------------------------------------------- def update_window_z if @file_index == 0 @savefile_windows[0].z = 2 end end #-------------------------------------------------------------------------- # * Frame Update (File Window Opacity) #-------------------------------------------------------------------------- def update_window_opacity if @file_index == 0 @savefile_windows[0].contents_opacity = @win_opac end end end |
el que tu pediste es la version 1.0 esta es la 1.2 y no creo que de errores porque las imagenes que usa tienen que ser las mismas si hay error me lo dices
chao |
|  | | chronoMx Aprendiz

Cantidad de envíos: 5 Miembro desde: 26/01/2012 Maker: 
 | Tema: Re: Ayuda con partida guardada Sáb Jun 02, 2012 9:12 am | |
| | Darkshadow escribió: | siento el doble post pero ya lo tienes listo
| Código: | #============================================================================== # ** MOG Scene File Ayumi V1.2 # By Moghunter # http://www.atelier-rgss.com #------------------------------------------------------------------------------ # ** Reinvisioned version # # This variant has retooled the MOG module by adding more configurables for # the user. No longer are the graphics hardwired into the code but are now # able to be altered in the revised configuration serction. # # Also, a few redundant modules have been deleted for compatability with # other systems. Please note that this system 'does' rewrite the save file # structure, so systems that append to the save file may need to be edited # for use with this script. #==============================================================================
module MOG # BASIC MENU CONFIGURATION # File Graphics Used FILE_LAYOUT = "Layout-File" # File Menu Graphics FILE_BACKGROUND = "Back-Other" # Animated background graphic FILE_STATUS = "Status-File" # File Window Graphic FACE_LARGE = "_Fl" # Suffix for large face graphics # File Effects FILE_MOVE_FX = false # If savefile moves side-to-side FILE_OPACITY_FX = false # If savefile changes opacity # Menu FILE_FX = 0 # Back FX (0=Moving/ 1=Still/ 2=Map) FILE_TRAN_TIME = 20 # Transition Time FILE_TRAN_TYPE = "004-Blind04" # Transition Type (Name) # Font Used FILE_FONT = "Georgia" # Font used in file menu end
# Mogscript global $mogscript = {} if $mogscript == nil $mogscript["menu_ayumi"] = true
#============================================================================== # ** Game_Map #------------------------------------------------------------------------------ # This class handles the map. It includes scrolling and passable determining # functions. Refer to "$game_map" for the instance of this class. #==============================================================================
class Game_Map #-------------------------------------------------------------------------- # * Get Map Name #-------------------------------------------------------------------------- def map_name @mapinfo = load_data("Data/MapInfos.rxdata") if @mapinfo == nil return @mapinfo[@map_id].name end end
#============================================================================== # ** Window_Base #------------------------------------------------------------------------------ # This class is for all in-game windows. #==============================================================================
class Window_Base < Window #-------------------------------------------------------------------------- # * Draw File Window # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def drw_win_file(x, y) dwf = RPG::Cache.picture(MOG::FILE_STATUS) cw = dwf.width ch = dwf.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, dwf, src_rect) end #-------------------------------------------------------------------------- # * Draw Empty Face #-------------------------------------------------------------------------- def nada face = RPG::Cache.picture("") end #-------------------------------------------------------------------------- # * Draw Face #3 (Larger face) # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_heroface3(actor, x, y) face = RPG::Cache.picture(actor.name + MOG::FACE_LARGE) rescue nada cw = face.width ch = face.height src_rect = Rect.new(0, 0, cw, ch) self.contents.blt(x , y - ch, face, src_rect) end #-------------------------------------------------------------------------- # * Draw Actor Level #6 # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_actor_level6(actor, x, y) self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 1, y + 1, 32, 32, "Lv") self.contents.font.color = system_color self.contents.draw_text(x, y, 32, 32, "Lv") self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 17, y + 1, 24, 32, actor.level.to_s, 2) self.contents.font.color = Color.new(255, 255, 255, 255) self.contents.draw_text(x + 16, y, 24, 32, actor.level.to_s, 2) end #-------------------------------------------------------------------------- # * Draw Actor Name #6 # actor : actor # x : draw spot x-coordinate # y : draw spot y-coordinate #-------------------------------------------------------------------------- def draw_actor_name6(actor, x, y) self.contents.font.color = Color.new(0, 0, 0, 255) self.contents.draw_text(x + 1, y + 1, 100, 32, actor.name, 1) self.contents.font.color = normal_color self.contents.draw_text(x, y, 100, 32, actor.name, 1) end end
#============================================================================== # ** Window_SaveFile #------------------------------------------------------------------------------ # This window displays save files on the save and load screens. #==============================================================================
class Window_SaveFile < Window_Base #-------------------------------------------------------------------------- # * Object Initialization # file_index : save file index (0-3) # filename : file name #-------------------------------------------------------------------------- def initialize(file_index, filename) super(0, 64 + file_index * 138, 640, 240) self.contents = Bitmap.new(width - 32, height - 32) self.opacity = 0 @file_index = file_index @filename = "Save#{@file_index + 1}.rxdata" @time_stamp = Time.at(0) @file_exist = FileTest.exist?(@filename) if @file_exist file = File.open(@filename, "r") @time_stamp = file.mtime @characters = Marshal.load(file) @frame_count = Marshal.load(file) @game_system = Marshal.load(file) @game_switches = Marshal.load(file) @game_variables = Marshal.load(file) @game_self_switches = Marshal.load(file) @game_screen = Marshal.load(file) @game_actors = Marshal.load(file) @game_party = Marshal.load(file) @game_troop = Marshal.load(file) @game_map = Marshal.load(file) @total_sec = @frame_count / Graphics.frame_rate file.close end @wiref = 0 refresh @selected = false end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh self.contents.clear self.contents.font.name = MOG::FILE_FONT drw_win_file(0,190) name = "#{@file_index + 1}" self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(161, 41, 600, 32, name) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(160, 40, 600, 32, name) @name_width = contents.text_size(name).width if @file_exist for i in 0...@characters.size bitmap = RPG::Cache.character(@characters[i][0], @characters[i][1]) cw = bitmap.rect.width / 4 ch = bitmap.rect.height / 4 src_rect = Rect.new(cw * @wiref + 1 , 0, cw, ch) x = 300 - @characters.size + i * 64 - cw / 4 self.contents.blt(x - 10, 150 - ch, bitmap, src_rect) x = 116 actors = @game_party.actors for i in 0...[actors.size, 4].min x = i * 60 actor = actors[i] self.contents.font.size = 20 draw_actor_level6(actor, x + 280, 140) actor = actors[0] draw_heroface3(actor,160,180) draw_actor_name6(actor, 160, 155) self.contents.font.size = 22 end end hour = @total_sec / 60 / 60 min = @total_sec / 60 % 60 sec = @total_sec % 60 time_string = sprintf("%02d:%02d:%02d", hour, min, sec) self.contents.font.color = Color.new(0,0,0,255) self.contents.draw_text(5, 41, 450, 32, time_string, 2) self.contents.draw_text(41 , 141, 120 , 32, @game_map.map_name.to_s) self.contents.font.color = Color.new(255,255,255,255) self.contents.draw_text(40 , 140, 120 , 32, @game_map.map_name.to_s) self.contents.draw_text(4, 40, 450, 32, time_string, 2) end end #-------------------------------------------------------------------------- # * Set Selected # selected : new selected (true = selected, false = unselected) #-------------------------------------------------------------------------- def selected=(selected) @selected = selected end end
#============================================================================== # ** Scene_Save #------------------------------------------------------------------------------ # This class performs save screen processing. #==============================================================================
class Scene_Save < Scene_File #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- alias mog_init initialize def initialize mog_init $mog_scene_filesave_flag = 1 end end
#============================================================================== # ** Scene_File #------------------------------------------------------------------------------ # This is a superclass for the save screen and load screen. #==============================================================================
class Scene_File #-------------------------------------------------------------------------- # * Main Processing #-------------------------------------------------------------------------- def main if $mog_scene_filesave_flag != 1 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 else if MOG::FILE_FX == 0 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 elsif MOG::FILE_FX == 1 @mnback = Plane.new @mnback.bitmap = RPG::Cache.picture(MOG::FILE_BACKGROUND) @mnback.z = 1 else @spriteset = Spriteset_Map.new end end @mnlay = Sprite.new @mnlay.bitmap = RPG::Cache.picture(MOG::FILE_LAYOUT) @mnlay.z = 2 @help_window = Window_Help.new @help_window.set_text(@help_text) @help_window.opacity = 0 @savefile_windows = [] @cursor_displace = 0 for i in 0..0 @savefile_windows.push(Window_SaveFile.new(i, make_filename(i))) end @savefile_windows[0] @file_index = $game_temp.last_file_index @savefile_windows[@file_index].selected = true @savefile_windows[0].y = 40 #@savefile_windows[1].y = 140 #@savefile_windows[2].y = 240 @win_move_time = 0 @win_move = 0 @win_dire = 0 @win_opac = 255 @win1_y = 0 @win2_y = 0 @win3_y = 0 unless MOG::FILE_FX == 2 Graphics.transition(MOG::FILE_TRAN_TIME, "Graphics/Transitions/" + MOG::FILE_TRAN_TYPE) else Graphics.transition end loop do Graphics.update Input.update update if $scene != self break end end for i in 0..50 @mnback.ox += 1 if MOG::FILE_FX == 0 @savefile_windows[0].x += 10 for i in @savefile_windows i.contents_opacity -= 5 end Graphics.update end Graphics.freeze @help_window.dispose @mnback.dispose if MOG::FILE_FX == 0 @mnback.dispose if MOG::FILE_FX == 1 @mnback.dispose if MOG::FILE_FX == 2 && $mog_scene_filesave_flag != 1 @spriteset.dispose if MOG::FILE_FX == 2 && $mog_scene_filesave_flag == 1 $mog_scene_filesave_flag = 0 @mnlay.dispose for i in @savefile_windows ; i.dispose ; end end #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update @mnback.ox += 1 if MOG::FILE_FX == 0 if MOG::FILE_OPACITY_FX @win_opac += 3 @win_opac = 150 if @win_opac > 254 else @win_opac = 255 end @win_move_time += 1 if @win_move_time > 60 @win_dire += 1 @win_move_time = 0 end @win_dire = 0 if @win_dire > 1 if @win_dire == 0 @win_move += 1 else @win_move -= 1 end # Update File Windows update_window_z update_moving_window if MOG::FILE_MOVE_FX update_window_opacity @help_window.update for i in @savefile_windows ; i.update ; end if Input.trigger?(Input::C) on_decision(make_filename(@file_index)) $game_temp.last_file_index = @file_index return end if Input.trigger?(Input::B) on_cancel return end end #-------------------------------------------------------------------------- # * Frame Update (Reposition File Window) #-------------------------------------------------------------------------- def update_window_z if @file_index == 0 @savefile_windows[0].z = 2 end end #-------------------------------------------------------------------------- # * Frame Update (File Window Opacity) #-------------------------------------------------------------------------- def update_window_opacity if @file_index == 0 @savefile_windows[0].contents_opacity = @win_opac end end end |
el que tu pediste es la version 1.0 esta es la 1.2 y no creo que de errores porque las imagenes que usa tienen que ser las mismas si hay error me lo dices
chao |
Gracias amigo, esto es lo que buscaba, oye pero no tendras las imagenes? las que trae la version 1.0 no funcionan le acomode otras para provarlo pero se ve medio feo pero en verdad muchas gracias mi proyetco tendra tu nick en los creditos!! |
|  | | | | Ayuda con partida guardada | |
|
Temas similares |  |
|
| | Permisos de este foro: | No puedes responder a temas en este foro.
| |
| |
| |