I have a question regarding a selfwritten savesystem im currently "scripting" using the autosave-system.
So i have 8 available saveslots in my interface(!) menu to save an autosave file from (bookmark01.dat - bookmark08.dat).
Currently i also create (and read) a file called "savegames.ini" and write down the date and name of each savegame (name is the current scene).
Regarding to this i have to load the savegames.ini file to set some values ingame to the correct strings so they can be displayed as an object text in my save/load menu.
The savegames.ini looks like that after saved on slot 1 and 4 on different dates:
# Naming the savegames
savegame_1 = Room 1 06.08.15 23:05
savegame_2 = empty
savegame_3 = empty
savegame_4 = Room 2 07.08.15 13:34
savegame_5 = empty
savegame_6 = empty
savegame_7 = empty
savegame_8 = empty
When opening the save/load menu a function loads these lines into variables so they are up to date.
Works nice so far.
The problem i have here now is a "what if" scenario:
A) bookmark01.dat doesn't exist but a line in the savegames.ini still names it. So i have to check if it really exists and if not rewriting the variable to "Empty Slot".
B) bookmark01.dat does exist but the entry in the savegames.ini file is missing. So i have to rename the slot to some kind of "sorry, forgot the name" -kind entry.
So how do i solve this?
I could to a filechecking, etc before loading these variables BUT MAYBE it is possible to read the current room name outside of the bookmark files and also load the creation/update-date / time from that file directly to load them up into variables from visionaire. So i have no trouble building a whole system around said bookmark files and a check system if these files still exist or entries are missing...
So is it possible to access these bookmark files via Lua to extract some desired information ?