love.filesystem.load() behavior
Posted: Thu Mar 07, 2013 9:52 pm
Hey,
I use love.filesystem.load() to load my levels on the fly. My level files are located at the path : "data/levels/" inside of my love archive. Most of time I test my prototype without zipping it to a .love file, and everything works fine.
Recently, I tried to run my .love file on a windows computer and I got a file not found error when invoking the following line:
Notice that my level files have no extension, on purpose.
While reading the wiki (http://www.love2d.org/wiki/love.filesystem) I saw :
I also tried backslashes instead of slashes, and also adding a / before my path (e.g. /data/levels/level_0 ) and it didn't help.
I use love.filesystem.load() to load my levels on the fly. My level files are located at the path : "data/levels/" inside of my love archive. Most of time I test my prototype without zipping it to a .love file, and everything works fine.
Recently, I tried to run my .love file on a windows computer and I got a file not found error when invoking the following line:
Code: Select all
love.filesystem.load( "data/levels/level_0" )
While reading the wiki (http://www.love2d.org/wiki/love.filesystem) I saw :
Does it means that I can't access subfolders of my love archive? If not, what did I do wrong?This module provides access to files in two places, and two places only:
The root folder of the .love archive (or source directory)
The root folder of the game's save directory.
I also tried backslashes instead of slashes, and also adding a / before my path (e.g. /data/levels/level_0 ) and it didn't help.