Search found 9 matches
- Tue Oct 09, 2018 8:44 am
- Forum: Libraries and Tools
- Topic: GetAss - A library to recursively parse a directory for game assets
- Replies: 6
- Views: 6910
Re: GetAss - A library to recursively parse a directory for game assets
Hey guys so thanks for the suggestions. I've added a bit more functionality. Firstly, there's sensible defaults now for the pattern and the function. The default pattern is "^"(find all files, don't remove anything from the filename) and the default function is function(filepath) return fi...
- Tue Oct 09, 2018 7:34 am
- Forum: Libraries and Tools
- Topic: X11Colors - List of all the X11 color names
- Replies: 0
- Views: 4782
X11Colors - List of all the X11 color names
Hey so I found this library and I liked the idea: https://love2d.org/forums/viewtopic.php?t=81151 I make this as a bigger version of the same idea. For those who don't know, the X11 color scheme is like a larger version of the HTML color names that you would use in your browser, except it has more s...
- Tue Oct 09, 2018 6:34 am
- Forum: Libraries and Tools
- Topic: GetAss - A library to recursively parse a directory for game assets
- Replies: 6
- Views: 6910
Re: GetAss - A library to recursively parse a directory for game assets
The code looks fine. I think returning a table of results is cleaner than having to provide a closure function. My suggestion would be to change the API a little bit: function getass(dir, pattern, result) result = result or {} local filenames = love.filesystem.getDirectoryItems(dir) for index, file...
- Mon Oct 08, 2018 6:13 pm
- Forum: Libraries and Tools
- Topic: GetAss - A library to recursively parse a directory for game assets
- Replies: 6
- Views: 6910
Re: GetAss - A library to recursively parse a directory for game assets
I like this, I've sent you a PM to discuss how you can expand this for any type of file. Didn't want to hijack your library thread. :awesome: Haven't received PM but I really don't mind the thread getting hijacked. Feel free to comment right here. The thread is about the library in general, not abo...
- Mon Oct 08, 2018 5:17 pm
- Forum: Libraries and Tools
- Topic: GetAss - A library to recursively parse a directory for game assets
- Replies: 6
- Views: 6910
GetAss - A library to recursively parse a directory for game assets
Hi there. So I'm pretty new to Love2D but I came up with this simple library to parse a directory for game asset files and create a table-tree for the assets based on the directory structure. This allows you to very easily access the assets just as they are organized in the filesystem. The usage is ...
- Thu Sep 27, 2018 12:18 pm
- Forum: Support and Development
- Topic: Detecting screen rotation on IOS?
- Replies: 4
- Views: 4532
Re: Detecting screen rotation on IOS?
It seems it's a problem with SDL on iOS. https://discourse.libsdl.org/t/sdl-2-0-opengles-and-iphone-orientation/20701 It only submits events on portrait-landscape changes, not on flips. Surely somebody else has done this sort of thing before using SDL? There must be a way to detect a flip or make th...
- Thu Sep 27, 2018 11:58 am
- Forum: Support and Development
- Topic: Detecting screen rotation on IOS?
- Replies: 4
- Views: 4532
Re: Detecting screen rotation on IOS?
Note that the event does get called if I enable t.window.resizable and if I go between portrait and landscape mode but it still does nothing if I go directly between landscape to opposite landscape or portrait to opposite portrait.
- Thu Sep 27, 2018 11:24 am
- Forum: Support and Development
- Topic: Detecting screen rotation on IOS?
- Replies: 4
- Views: 4532
Re: Detecting screen rotation on IOS?
Use the call back love.resize and print the arguments. Iirc on iOS when the rotation is set to auto the resize call back will be called. You can also set the orientation using setWindow I believe. Doesn't seem to work. Note that the rotation I'm talking about is rotating from horizontal to the oppo...
- Wed Sep 26, 2018 9:14 pm
- Forum: Support and Development
- Topic: Detecting screen rotation on IOS?
- Replies: 4
- Views: 4532
Detecting screen rotation on IOS?
Hi all. Very new to Love2d and enjoying it so far. Just screwing around with mobile game dev and I've run into a problem with gyroscope access on iPad. I have an iPad mini and I've made a super basic game that just moves a circle around on the screen in the direction you tilt it. Seems to work fine ...