Check if Save File exists

sertianscompany

Villager
Member
Joined
Nov 26, 2015
Messages
16
Reaction score
5
First Language
ESP EN
Hello everyone! :)

I know this problem is solved and closed here: http://forums.rpgmakerweb.com/index.php?/topic/49606-checking-if-save-file-is-present/#entry491552

Buuuuut, it doesn't work for me, so I guess I'm doing something wrong.

basically I want to check (using the conditional branch) if a save file exists.

 I tried using  File.exists("Save01.rvdata2") in the Script box (inside the conditional) but the program says "Undefined is not a function" (I tried as well File.exists?("Save01.rvdata2") but it says "Unexpected end of input").

Also I tried DataManager.save_file_exists? and same problem (Unexpected end of input), so I removed the "?" and no error message but it doesn´t detect the save file.

My save files are inside the save folder.



Any ideas? :unsure:

save files.png
 
Last edited by a moderator:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
Look at the default scripts. They do a check to see if a save file exists when displaying the title screen, in order to tell whether to enable the Continue option or not.


In fact, DataManager.isAnySavefileExists() will give you a true/false answer depending on whether there are any save files.
 

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

Latest Threads

Latest Profile Posts

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD

Forum statistics

Threads
105,868
Messages
1,017,070
Members
137,577
Latest member
SadaSoda
Top