Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
App still crashing after second upload to App store — Gideros Forum

App still crashing after second upload to App store

Tom2012Tom2012 Guru
edited November 2012 in General questions
Narrowed it down to this part of the code, which loads the save file...
local function fileExists(fileName)
	local file = io.open(fileName)
	if file ~= nil then
		io.close(file)
	end
	return file == nil
end
 
 
if(fileExists("|D|saveTable")) then
print("|D|saveTable exists");
else
print("|D|saveTable DOES NOT exists");
 
end

Comments

  • Tom2012Tom2012 Guru
    edited November 2012
    Edit - I have fixed it with this:
    local file = io.open("|D|saveGame.json", "r" )
    	if file then
    		io.close( file )
    ... your code here
    BTW if anyone is having problems with saving / loading - it really helps to get a tool called iExplorer, which lets you browse the save files and view them on your device.
Sign In or Register to comment.