Love2D I/O to any directory?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
-
- Citizen
- Posts: 87
- Joined: Tue Dec 30, 2014 6:07 pm
Re: Love2D I/O to any directory?
Wouldn't you need different binaries again for Android and iOS?
-
- Party member
- Posts: 730
- Joined: Sat Apr 26, 2014 7:46 pm
Re: Love2D I/O to any directory?
Yeah. Idk if luafilesystem works on those platforms.
But it doesn't matter to the OP. He is making a desktop application presumably.
But it doesn't matter to the OP. He is making a desktop application presumably.
- Positive07
- Party member
- Posts: 1014
- Joined: Sun Aug 12, 2012 4:34 pm
- Location: Argentina
Re: Love2D I/O to any directory?
Fused games can load dlls from the Save folder (applies to all platforms)
Also I must point out this library which may fit better what you need. I'm pointing to my pull-request since there are instructions for building on Windows, you could also build it for Linux using GTK file dialogs or in MacOS X where you would get native Cocoa file dialogs, you just need to compile, package the library with your game and require "nfs" which provides three functions, each returns a path to the file selected:
All functions are blocking, if you don't want to block the game run them from a thread
Also I must point out this library which may fit better what you need. I'm pointing to my pull-request since there are instructions for building on Windows, you could also build it for Linux using GTK file dialogs or in MacOS X where you would get native Cocoa file dialogs, you just need to compile, package the library with your game and require "nfs" which provides three functions, each returns a path to the file selected:
Code: Select all
local nfs = require "nfs"
--Open a file from the image folder, filters them out by image extensions
local path = nfs.open("png;jpg,jpeg;bmp", "C:\Users\user\Images")
print(path)
--There is also nfs.openMany(filter, path) which lets the user pick multiple files and returns a table with all the files paths
--And there is also nfs.save(filter, path) which works the same way as nfs.open
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Who is online
Users browsing this forum: Ahrefs [Bot], Semrush [Bot] and 3 guests