The RPG Maker Resource Kit

RMRK RPG Maker Creation => Requests => Script Request => Topic started by: creepercrisis on January 06, 2012, 09:20:38 PM

Title: [RMVX] Script that...
Post by: creepercrisis on January 06, 2012, 09:20:38 PM
Hello and this is my first post there! :D (And Edited xD)

Saves in Documents
January 06 2012



Summary
Script that allows you to save states in folder in Documents.

Features Desired

Mockups
(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg585.imageshack.us%2Fimg585%2F9930%2Fmyidea.png&hash=b56f9b5165b5d6cc04c5929dce0dcd8b34ffb30e)

Games its been in



Did you search?
Yes...

Where did you search?

What did you search for?
Title: Re: [RMVX] Script that...
Post by: Bigace on January 08, 2012, 03:45:13 AM
Little piece of advice. Read the stickies. Most people are going to glance right over this and not do anything about it
Title: Re: [RMVX] Script that...
Post by: DoctorTodd on January 08, 2012, 05:57:56 AM
Well I am! but ya read the stickies there important. You can try this http://rmrk.net/index.php/topic,39460.0.html (http://rmrk.net/index.php/topic,39460.0.html)
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 08, 2012, 03:07:20 PM
Thanks for help, but I used this script before and I changed:

Code: [Select]
SAVE_PATH = '' # Path to store save file, e.g. 'Save/' or '' (for game folder).

&

Code: [Select]
Dir.mkdir(SAVE_PATH) if !FileTest.directory?(SAVE_PATH)

into:

Code: [Select]
SAVE_PATH = ' %USERDATA%/Documents/My Games/Zagubiony Saves/' # Path to store save file, e.g. 'Save/' or '' (for game folder).

&

Code: [Select]
Dir[SAVE_PATH] if !FileTest.directory?(SAVE_PATH)

When I'm pressing Enter to save game It pops up:
(https://rmrk.net/proxy.php?request=http%3A%2F%2Fimg683.imageshack.us%2Fimg683%2F9930%2Fmyidea.png&hash=eeaf3182cfbc17e12ef20664bd8bf61b6779e53d)

I think this script first creates screenshot and ruby doesn't care Windows shortcuts xD It must be something with this %USERDATA%. How I can fix this. Thanks a lot :D
Title: Re: [RMVX] Script that...
Post by: DoctorTodd on January 08, 2012, 03:40:46 PM
Did you download screeshot.dll and put it in your game folder?
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 08, 2012, 03:41:49 PM
Yes :D I have this in game folder. :P
Title: Re: [RMVX] Script that...
Post by: Zeriab on January 08, 2012, 03:46:06 PM
You'd want to use the %USERPROFILE% instead, but I suggest that you don't as there can be trouble with certain usernames unless you are using the 8.3 shortname for the path.
You can retrieve it using the .dll Amanda made in her Commercial Game Kit: http://www.rpgrevolution.com/forums/index.php?showtopic=35647

*hugs*
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 08, 2012, 06:41:37 PM
What I must do with this DLL xD I don't care this
Title: Re: [RMVX] Script that...
Post by: Zeriab on January 08, 2012, 06:59:50 PM
Look at code used to figure out where to put the saves in that project I linked to.
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 08, 2012, 09:05:09 PM
Now I understand xD Thanks a lot! :D It's working perfectly :P
Title: Re: [RMVX] Script that...
Post by: Zeriab on January 08, 2012, 11:49:14 PM
That's great to hear.
I'm glad I was able to prevent a nasty surprise where some players wouldn't be able to save their games ^_^
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 09, 2012, 03:36:59 PM
I added AutoSave. :P When player will finish the part I of game (like discs in Final Fantasy on PSX :P) it will save. This save is required to play part II. But nevermind. You can now close this topic :P Problem solved. :D
Title: Re: [RMVX] Script that...
Post by: Zeriab on January 09, 2012, 07:48:58 PM
It's nice that your problem is solved :3
I'll keep it open so other trying to do the same thing can ask for help should they have trouble following the information here.

*hugs*
Title: Re: [RMVX] Script that...
Post by: creepercrisis on January 12, 2012, 06:26:03 PM
Error again xD My game can't enable load scene in title screen. Maybe it's a problem with SAVE_PATH:

Code: [Select]
class Scene_Title < Scene_Base

  def check_continue
    file_name = Wora_NSS::SAVE_PATH + Wora_NSS::SAVE_FILE_NAME.gsub(/\{ID\}/i) { '*' }
    @continue_enabled = (Dir.glob(file_name).size > 0)
  end

end

Thanks a lot :P

PS I didn't change anything in this part of script