Advertisement
AriArk

AriArk's Save Options

Sep 4th, 2013
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 1.62 KB | None | 0 0
  1. #----------------------------------------------------------------------------
  2. # AriArk's Save Options
  3. # Version 1.00
  4. #----------------------------------------------------------------------------
  5. # This script allows you to change two things about saving.
  6. # 1. The maximum amount of save files allowed
  7. # 2. The name of save files
  8. #----------------------------------------------------------------------------
  9. module DataManager
  10.   def self.init2
  11. #----------------------------------------------------------------------------
  12. #                              CUSTOM SETTINGS
  13. #----------------------------------------------------------------------------
  14. # Maximum Save Files
  15. #----------------------------------------------------------------------------
  16.    
  17.  
  18.  
  19.    @save_file_max = 16   # deafult 16
  20.  
  21.    
  22.      
  23. #----------------------------------------------------------------------------
  24. # Name of Save Files
  25. #----------------------------------------------------------------------------
  26.    
  27.  
  28.  
  29.    @save_name = "save"   # deafult "save"
  30.  
  31.    
  32.    
  33. #----------------------------------------------------------------------------
  34.                            end #OF CUSTOM SETTINGS
  35. #----------------------------------------------------------------------------
  36. #            DO NOT EDIT ANYTHING BELOW IF YOU DO NOT KNOW RUBY!!!
  37. #----------------------------------------------------------------------------
  38.   def self.savefile_max
  39.     return @save_file_max
  40.   end
  41.   def self.save_file_exists?
  42.     !Dir.glob(@save_name + '*.rvdata2').empty?
  43.   end
  44.   def self.make_filename(index)
  45.     sprintf(@save_name + "%02d.rvdata2", index + 1)
  46.   end
  47. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement