Hey guys I need help!
I'm trying to upload a png file with the name blocky.png. My love.exe file is in the C: drive and this is how I tried loading it.
local heroman
function love.load()
heroman = love.graphics.newImage("C:\Users\Kazabite\Desktop\Engine\gfx\blocky.png")
end
where Kazabite is the user name, Engine is the file where main.lua is present and gfx where the png file is located.
However, I get an error that there is an invalid escape sequence near '"C;'
And by default, that's not going to work, löve only supports relative paths from where your main.lua is, and the project's save directory; It does not support absolute paths like what you are trying. (hence why i linked you to this thread if absolute paths would be a necessity to you; clearly they aren't)
But, assuming that your main.lua is in the Engine folder, you'd do love.graphics.newImage("gfx\blocky.png") and that should work.
Me and my stuff True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
Darlex wrote: ↑Sun May 05, 2019 4:47 pm
I want to give that sensation of comfort of saving and loading files from anywhere to anywhere.
Frankly speaking, I don't see anything "comfortable" in dealing with file dialogs, etc.
In fact, most modern programs never ask you to browse around the device's filesystem.
A good example would be apps on Android and iOS.
Im not thinking about creating a game editor for android or ios