"Re-Designing" The Save System

Evgenij

Veteran
Veteran
Joined
Aug 28, 2013
Messages
349
Reaction score
100
First Language
German
Primarily Uses
N/A
Hey,

you dont need to make your own counter. There is a counter already buildin: $game_system.save_count will give you the current save_count, just add this to the header instead of your custom made.
 

Goldstorm

ᕕ( ͡° ͜ʖ ͡°)ᕗ
Veteran
Joined
Jul 21, 2013
Messages
320
Reaction score
186
First Language
English
Primarily Uses
Hey,

you dont need to make your own counter. There is a counter already buildin: $game_system.save_count will give you the current save_count, just add this to the header instead of your custom made.
Thanks a bunch for the feedback! Saved me a few lines of code. :)
 

optimum45

Veteran
Veteran
Joined
Mar 31, 2015
Messages
537
Reaction score
65
First Language
English
Primarily Uses
I will insert this into the current project and see how it looks on my end.  I think you have it pretty well nailed, but we'll give "her" a test.  I'll post screenshots when I have them.   :rock-left:
 

Goldstorm

ᕕ( ͡° ͜ʖ ͡°)ᕗ
Veteran
Joined
Jul 21, 2013
Messages
320
Reaction score
186
First Language
English
Primarily Uses
I will insert this into the current project and see how it looks on my end.  I think you have it pretty well nailed, but we'll give "her" a test.  I'll post screenshots when I have them.   :rock-left:
Alright, give it a go! I went ahead and updated the script (so the version you are using is older). Let me know your feedback in here and I'll post you the newer one with feedback from you later. :) Remember, your map name is your chapter name.

################################################################################ Created By Goldstorm                                                        ## Version 0.4 - 8/12/2015 1410 EDT                                            ## This script adds a save counter, and shows the current Map Name the player  ## is on in the save file.                                                     ####################################################################################################################################################################  Change the variables to show what it says on the save/load screen  ####################################################################################module Vocab  SaveMessage     = "Write to book?"  LoadMessage     = "Read which book?"  File            = "Bookmark"  SaveCounter     = "Books Read:"endmodule DataManager; module GOLD####################################################################################      ADJUST THESE NUMBERS TO MOVE THE TEXT ON THE SAVE SCREEN       ####################################################################################    X_PLAYT       = -430 #Adjust Playtime X Axis Location    Y_PLAYT       = 20   #Adjust Playtime Y Axis Location    X_FILES       = 4    #Adjust the Vocab::File String X Axis    Y_FILES       = 0    #Adjust the Vocab::File String Y Axis    X_BOOKM       = 4    #Adjusts the Vocab::SaveCounter String X Axis    Y_BOOKM       = 40   #Adjusts the Vocab::SaveCounter String Y Axis    X_SAVEN       = -378 #Adjusts Save Counter X Axis Location    Y_SAVEN       = 40   #Adjusts Save Counter Y Axis Location    X_SPRITE      = 152  #Adjust Sprite X Axis Location    Y_SPRITE      = 58   #Adjust Sprite Y Axis Location    X_MAPLOC      = 0    #Adjust Map Name X Axis Location    Y_MAPLOC      = 0    #AdjuSt Map Name Y Axis Locationend####################################################################################         DON'T ADJUST ANYTHING BELOW HERE, OR DO, WHATEVER...        #####################################################################################Add another header  def self.make_save_header    header = {}    header[:characters] = $game_party.characters_for_savefile    header[:playtime_s] = $game_system.playtime_s    header[:savenum]    = $game_system.save_count    header[:currentmap] = $game_map.display_name    header  endend class Window_SaveFile < Window_Base   #--------------------------------------------------------------------------  # * OVERWRITE Refresh  #--------------------------------------------------------------------------  def refresh    contents.clear    change_color(normal_color)    name = Vocab::File + " #{@file_index + 1}"    draw_text(DataManager::GOLD::X_FILES, DataManager::GOLD::Y_FILES, 200, line_height, name)    @name_width = text_size(name).width    draw_party_characters(DataManager::GOLD::X_SPRITE, DataManager::GOLD::Y_SPRITE)    draw_playtime(0, contents.height - line_height, contents.width - 4, 2)    book = Vocab::SaveCounter    draw_text(DataManager::GOLD::X_BOOKM, DataManager::GOLD::Y_BOOKM, 200, line_height, book)    draw_savenums(0, contents.height - line_height, contents.width - 4, 2)    draw_gamemap(0, contents.height, contents.width - 4, 2)  end   #--------------------------------------------------------------------------  # * OVERWRITE Draw Play Time  #--------------------------------------------------------------------------  def draw_playtime(x, y, width, align)    header = DataManager.load_header(@file_index)    return unless header    draw_text(DataManager::GOLD::X_PLAYT, DataManager::GOLD::Y_PLAYT, width, line_height, header[:playtime_s], 2)  end   #--------------------------------------------------------------------------  # * Draw Save Number  #--------------------------------------------------------------------------  def draw_savenums(x, y, width, align)    header = DataManager.load_header(@file_index)    return unless header    draw_text(DataManager::GOLD::X_SAVEN, DataManager::GOLD::Y_SAVEN, width, line_height, header[:savenum], 2)  end   #--------------------------------------------------------------------------  # * Draw Game Map  #--------------------------------------------------------------------------  def draw_gamemap(x, y, width, align)    header = DataManager.load_header(@file_index)    return unless header    draw_text(DataManager::GOLD::X_MAPLOC, DataManager::GOLD::Y_MAPLOC, width, line_height, header[:currentmap], 2)  endendScreen Shot:

 
Last edited by a moderator:

optimum45

Veteran
Veteran
Joined
Mar 31, 2015
Messages
537
Reaction score
65
First Language
English
Primarily Uses


This is how it came out on my end, just inserting the script.  I think it looks good, and only requires a little bit of tweaking on my end to make it "fit".

My windowskin and character are, of course, automatic.  But there is that "Extra_Y" that makes my entire save box a little taller.

I like the format from here, and I think I can manipulate it to working for my project.
 

Goldstorm

ᕕ( ͡° ͜ʖ ͡°)ᕗ
Veteran
Joined
Jul 21, 2013
Messages
320
Reaction score
186
First Language
English
Primarily Uses


This is how it came out on my end, just inserting the script.  I think it looks good, and only requires a little bit of tweaking on my end to make it "fit".

My windowskin and character are, of course, automatic.  But there is that "Extra_Y" that makes my entire save box a little taller.

I like the format from here, and I think I can manipulate it to working for my project.
Sounds good, if you want to make edits, use the second version of the code I posted a bit ago. I made it so you can move a lot more things as well.

Glad I could help and you like it. If you run into any issues, let me know and I'll be happy to work through them with you. :)
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

I based this on the armor of Actor 1_7 of the RTP. Hair is from Derex and Sythian Bard.
Stream will be live shortly! Going to do another art stream tonight so that I can finish my Fauna Focus piece~ Feel free to drop by!
Humans are fallible creatures, we all know that. It's when we're forced to look at ourselves that we start to disagree. :p
Expectation: Working on boss battle.
Reality: "Look at how awful are these code and database organization. Let me clean this mess", *yet, casually adding more modules that I have no idea if I would use it later*
Trying to learn to read Japanese so I read my manga. I like to buy them without all the edits made during translation.

Forum statistics

Threads
97,864
Messages
947,449
Members
129,087
Latest member
jubacard
Top