Bart van Strien
ca343e063e
Allow require paths without replacements
...
--HG--
branch : minor
2015-01-14 15:17:16 +01:00
Bart van Strien
13594e3e38
Add missing include
...
--HG--
branch : minor
2015-01-14 15:16:04 +01:00
Alex Szpakowski
d4be84a630
Fixed love.filesystem.unmount.
...
--HG--
branch : minor
2014-10-19 01:52:48 -03:00
Alex Szpakowski
8d0654a6a7
Added runtime drag-and-drop file and folder support via new love.filedropped and love.directorydropped event callback functions. filedropped has a single File object argument, and directorydropped has a single string argument containing the full path of the directory, which can be used with love.filesystem.mount.
...
--HG--
branch : minor
2014-10-18 20:30:36 -03:00
Alex Szpakowski
8edb90a719
Added support for loading BMFont bitmap font files with love.graphics.newFont (see issue #190.) Some esoteric BMFont features are not supported.
...
Moved the Font module Lua wrapper code out of the freetype implementation folder.
--HG--
branch : minor
2014-09-28 16:00:40 -03:00
Alex Szpakowski
34688e929e
Merged default into minor
...
--HG--
branch : minor
2014-09-28 15:56:04 -03:00
Alex Szpakowski
808e533b02
Tweaked streaming Sources to use fewer OpenAL buffers (and increased the amount of decoded data per buffer to compensate), and removed some unnecessary #include statements.
2014-09-28 14:58:59 -03:00
Bart van Strien
5b4ef23772
Move require path into filesystem module
...
--HG--
branch : minor
2014-09-05 07:57:42 +02:00
Bart van Strien
ddf6816548
Add a require path (much like package.path) to love.filesystem, allowing to override the searched file paths for require
...
--HG--
branch : minor
2014-09-03 18:01:21 +02:00
Bart van Strien
23f2d617e0
Remove accidentally left-behind filesystem wrappers, minor compiles again
...
--HG--
branch : minor
2014-08-19 16:06:54 +02:00
Alex Szpakowski
9b1f7d7a6e
Merged default into minor
...
--HG--
branch : minor
2014-08-09 19:55:29 -03:00
Alex Szpakowski
da7cd267ea
Changed luax_pushtype to retain the pushed object itself, but only if the object isn't in the Lua state already.
...
Previously, calling e.g. love.graphics.getFont() 10,000 times would retain the object 10,000 times (and release it 10,000 times when the Font object was garbage-collected in the Lua state.) Now it will only retain it once and release it once.
2014-08-09 16:04:59 -03:00
Alex Szpakowski
53e63d48c9
Merged default into minor
...
--HG--
branch : minor
2014-08-07 18:10:19 -03:00
Alex Szpakowski
028108ea64
Improved the error message when physfs fails to open a filepath.
2014-08-06 20:16:15 -03:00
Alex Szpakowski
aa05664d4c
Merged default into minor
...
--HG--
branch : minor
2014-07-30 01:32:10 -03:00
Alex Szpakowski
73c0f1e222
Added love.filesystem.isSymlink, love.filesystem.setSymlinksEnabled, and love.filesystem.areSymlinksEnabled. Symbolic link support is disabled by default.
...
love.filesystem.isSymlink will always return false when symbolic link support is disabled, even if the given filepath is actually a symlink.
2014-07-24 00:31:11 -03:00
Alex Szpakowski
d52bab4221
Updated the new module changes to use more compile/link-time checking rather than runtime checking.
2014-07-21 15:12:01 -03:00
Alex Szpakowski
014b9a46e5
Updated the Lua wrapper code for modules to account for cases where the module's instance is removed from memory completely and recreated during the program's lifetime.
2014-07-21 14:52:01 -03:00
Bart van Strien
59ab602111
Normalize slashes in paths unless they are direct user input (XDG_DATA_HOME/APPDATA, specifically)
2014-07-15 13:16:37 +02:00
Alex Szpakowski
bfa3ec9369
Merged default into minor
...
--HG--
branch : minor
2014-06-05 03:02:50 -03:00
Alex Szpakowski
79b453653a
Added love.joystick.loadGamepadMappings (resolves issue #842 ), and Joystick:saveGamepadMapping.
...
The latter returns a mapping string, and the former loads a newline-separated list of mapping strings.
2014-06-04 15:50:06 -03:00
Alex Szpakowski
dfa319e01a
Replaced the EXCEPT_GUARD macro for converting love exceptions into Lua errors with the new luax_catchexcept function, which takes lambda function arguments.
2014-06-03 19:27:00 -03:00
Alex Szpakowski
724bdbd296
love.graphics.newImage, love.image.newImageData, etc. no longer leave Lua-owned FileData objects floating around waiting to be GC'd when called with filename arguments, resulting in less memory use on startup (resolves issue #890.)
...
Moved love.filesystem Lua wrapper code from src/modules/filesystem/physfs/ to src/modules/filesystem/.
2014-06-02 00:22:41 -03:00
Alex Szpakowski
53b20b63a5
Merged default into minor
...
--HG--
branch : minor
2014-05-21 21:16:37 -03:00
Alex Szpakowski
e25cdfc71c
Fixed creating and setting the write directory on some sandboxed operating systems
2014-05-05 00:27:42 -03:00
Alex Szpakowski
9d293af176
Fixed love.filesystem.setIdentity breaking if a file has been written to an old identity dir before the new setIdentity call
2014-05-04 04:10:46 -03:00
Alex Szpakowski
4d579074a1
Removed love.filesystem.exists (resolves issue #641.)
...
Use either love.filesystem.isFile or love.filesystem.isDirectory instead.
--HG--
branch : minor
2014-04-23 02:15:02 -03:00
Alex Szpakowski
50916825d0
Data::getSize now uses size_t instead of int
2014-03-18 03:50:00 -03:00
Alex Szpakowski
aba17607aa
Added an optional callback function argument to love.filesystem.getDirectoryItems. Callback function takes a single argument containing a filepath string.
...
For example: love.filesystem.getDirectoryItems("", print)
2014-03-17 20:14:53 -03:00
Alex Szpakowski
a13fd761cc
Updated love.filesystem's C library loader for require to look in paths added via love.filesystem.mount, when in fused mode
2014-03-12 06:19:56 -03:00
Alex Szpakowski
fda005c5ff
love.graphics.getScissor now has a proper C++ module method
2014-01-09 22:49:00 -04:00
Alex Szpakowski
3120a0e650
Goodbye 2013, hello 2014!
2014-01-03 17:28:58 -04:00
Alex Szpakowski
9c747f1476
Switched to using bearing and advance metrics from the actual bitmap glyph object, removed old unused method declarations in the Filesystem class.
2014-01-01 03:52:43 -04:00
Alex Szpakowski
ccc5535a82
The love.filesystem module searchers for require are now tried after package.preload instead of before.
2014-01-01 02:08:50 -04:00
Alex Szpakowski
279cecaa6b
Improved the error text for LÖVE’s module searchers (used in require.)
2013-12-31 22:31:08 -04:00
Alex Szpakowski
eb4fdf3bbe
Use a separate preprocessor define for using Framework #includes in OS X (resolves issue #796 )
2013-12-13 02:37:06 -04:00
Alex Szpakowski
3b532fdb70
Fixed an uncaught exception in File:getSize
2013-11-18 05:29:53 -04:00
Alex Szpakowski
8cc5364d15
Changed the SearchOrder argument of love.filesystem.setIdentity and love.filesystem.mount to a boolean (append) instead of an enum
2013-10-30 17:05:46 -03:00
Alex Szpakowski
249dad3cae
love.filesystem.mkdir -> love.filesystem.createDirectory, love.filesystem.enumerate -> love.filesystem.getDirectoryItems. Resolves issue #609 .
2013-10-20 04:07:37 -03:00
Bart van Strien
f6f8251234
Hopefully fix appdata dir creation on windows
2013-10-15 20:03:22 +02:00
Alex Szpakowski
8b7f151a4d
Added joystick vibration support for most common controllers (resolves issue #159 ).
...
Added Joystick:setVibration(left, right), Joystick:getVibration, and Joystick:isVibrationSupported.
left and right are numbers between 0 and 1 which correspond to the strength of the gamepad's left and right rumble motors, if it has them.
2013-10-05 01:54:41 -03:00
Bart van Strien
0e6786988e
Try to create appdata dir if it doesn't exist (hopefully resolves #680 )
2013-10-04 14:30:56 +02:00
Alex Szpakowski
8d5ddb9e34
Fixed some internal documentation (thanks to clang's -Wdocumentation)
2013-09-23 21:52:28 -03:00
Alex Szpakowski
06f80d5c08
Fixed undefined behaviour when love exceptions are converted into Lua errors (resolves issue #729 )
2013-09-05 23:17:29 -03:00
Alex Szpakowski
c15fc4453b
Re-added Data:getPointer (can be used with LuaJIT's FFI)
2013-08-29 17:16:21 -03:00
Alex Szpakowski
ec9dec6b80
Replaced luax_newtype with luax_pushtype (and added luax_rawnewtype for the old functionality of luax_newtype.)
...
luax_pushtype keeps the object in a weak table and checks the table before creating a new userdata, so it re-uses the object's existing wrapper userdata if it can, whenever the object is pushed to Lua.
This fixes some subtle issues with love objects, where using them as keys in tables would not always work as expected (https://love2d.org/forums/viewtopic.php?f=4&t=39398&p=112388#p112415 ). It also decreases the amount of new Lua objects created, saving the garbage collector some work.
2013-08-29 00:40:06 -03:00
Alex Szpakowski
daf50698b8
Added love.filesystem.getSourceBaseDirectory and changed love.filesystem.mount to allow mounting the path returned by love.filesystem.getSourceBaseDirectory in fused mode.
2013-08-10 20:11:50 -03:00
Alex Szpakowski
fc3affb9b9
Removed 'release mode' and love.releaseerrhand, and added love.filesystem.isFused (resolves issue #579 ).
...
Games which are fused (either via appending the .love to the executable or with --fused) automatically have the changes which previously only applied to fused games in release mode.
2013-08-05 15:02:50 -03:00
Alex Szpakowski
7a20bbc6c4
Added an optional search order enum ("first" or "last") to love.filesystem.setIdentity and love.filesystem.mount (resolves issue #694 )
2013-08-04 00:32:23 -03:00
Alex Szpakowski
a4ff39e0d4
Improved error checking for some enum strings (resolves issue #690 ).
...
Also moved love.audio.newSource from Lua code into C++ code
2013-08-03 21:24:43 -03:00