summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-07-20 17:06:06 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-07-20 17:06:06 +0800
commit002e0c1673fdc5bd76331aaa1359cbb0925dad2e (patch)
tree6cbd6e62f3119798f300c2b67927677ae0dceaaa
parent4bad35e608179e74c9ce186fa2038573055e574b (diff)
downloadlua-language-server-002e0c1673fdc5bd76331aaa1359cbb0925dad2e.zip
update
-rw-r--r--meta/3rd/love2d/library/.vscode/settings.json3
-rw-r--r--meta/3rd/love2d/library/love.audio.lua379
-rw-r--r--meta/3rd/love2d/library/love.data.lua56
-rw-r--r--meta/3rd/love2d/library/love.event.lua32
-rw-r--r--meta/3rd/love2d/library/love.filesystem.lua132
-rw-r--r--meta/3rd/love2d/library/love.font.lua133
-rw-r--r--meta/3rd/love2d/library/love.graphics.lua1483
-rw-r--r--meta/3rd/love2d/library/love.image.lua138
-rw-r--r--meta/3rd/love2d/library/love.joystick.lua153
-rw-r--r--meta/3rd/love2d/library/love.keyboard.lua14
-rw-r--r--meta/3rd/love2d/library/love.lua59
-rw-r--r--meta/3rd/love2d/library/love.math.lua303
-rw-r--r--meta/3rd/love2d/library/love.mouse.lua21
-rw-r--r--meta/3rd/love2d/library/love.physics.lua1997
-rw-r--r--meta/3rd/love2d/library/love.sound.lua88
-rw-r--r--meta/3rd/love2d/library/love.system.lua2
-rw-r--r--meta/3rd/love2d/library/love.thread.lua114
-rw-r--r--meta/3rd/love2d/library/love.touch.lua4
-rw-r--r--meta/3rd/love2d/library/love.video.lua5
-rw-r--r--meta/3rd/love2d/library/love.window.lua10
-rw-r--r--tools/love-api.lua99
21 files changed, 5003 insertions, 222 deletions
diff --git a/meta/3rd/love2d/library/.vscode/settings.json b/meta/3rd/love2d/library/.vscode/settings.json
new file mode 100644
index 00000000..a83b313e
--- /dev/null
+++ b/meta/3rd/love2d/library/.vscode/settings.json
@@ -0,0 +1,3 @@
+{
+ "Lua.runtime.version": "LuaJIT"
+} \ No newline at end of file
diff --git a/meta/3rd/love2d/library/love.audio.lua b/meta/3rd/love2d/library/love.audio.lua
index b323fc64..d1580612 100644
--- a/meta/3rd/love2d/library/love.audio.lua
+++ b/meta/3rd/love2d/library/love.audio.lua
@@ -16,7 +16,7 @@ function love.audio.getActiveSourceCount() end
---
---Returns the distance attenuation model.
---
----@return DistanceModel model # The current distance model. The default is 'inverseclamped'.
+---@return love.audio.DistanceModel model # The current distance model. The default is 'inverseclamped'.
function love.audio.getDistanceModel() end
---
@@ -102,7 +102,7 @@ function love.audio.isEffectsSupported() end
---@param bitdepth number # Bits per sample (8 or 16).
---@param channels number # 1 for mono or 2 for stereo.
---@param buffercount number # The number of buffers that can be queued up at any given time with Source:queue. Cannot be greater than 64. A sensible default (~8) is chosen if no value is specified.
----@return Source source # The new Source usable with Source:queue.
+---@return love.audio.Source source # The new Source usable with Source:queue.
function love.audio.newQueueableSource(samplerate, bitdepth, channels, buffercount) end
---
@@ -111,8 +111,8 @@ function love.audio.newQueueableSource(samplerate, bitdepth, channels, buffercou
---Sources created from SoundData are always static.
---
---@param filename string # The filepath to the audio file.
----@param type SourceType # Streaming or static source.
----@return Source source # A new Source that can play the specified audio.
+---@param type love.audio.SourceType # Streaming or static source.
+---@return love.audio.Source source # A new Source that can play the specified audio.
function love.audio.newSource(filename, type) end
---
@@ -124,13 +124,13 @@ function love.audio.pause() end
---
---Plays the specified Source.
---
----@param source Source # The Source to play.
+---@param source love.audio.Source # The Source to play.
function love.audio.play(source) end
---
---Sets the distance attenuation model.
---
----@param model DistanceModel # The new distance model.
+---@param model love.audio.DistanceModel # The new distance model.
function love.audio.setDistanceModel(model) end
---
@@ -189,3 +189,370 @@ function love.audio.setVolume(volume) end
---Stops currently played sources.
---
function love.audio.stop() end
+
+---@class love.audio.RecordingDevice: love.audio.Object
+local RecordingDevice = {}
+
+---
+---Gets the number of bits per sample in the data currently being recorded.
+---
+---@return number bits # The number of bits per sample in the data that's currently being recorded.
+function RecordingDevice:getBitDepth() end
+
+---
+---Gets the number of bits per sample in the data currently being recorded.
+---
+---@return number bits # The number of bits per sample in the data that's currently being recorded.
+function RecordingDevice:getBitDepth() end
+
+---
+---Gets the number of channels currently being recorded (mono or stereo).
+---
+---@return number channels # The number of channels being recorded (1 for mono, 2 for stereo).
+function RecordingDevice:getChannelCount() end
+
+---
+---Gets all recorded audio SoundData stored in the device's internal ring buffer.
+---
+---The internal ring buffer is cleared when this function is called, so calling it again will only get audio recorded after the previous call. If the device's internal ring buffer completely fills up before getData is called, the oldest data that doesn't fit into the buffer will be lost.
+---
+---@return love.audio.SoundData data # The recorded audio data, or nil if the device isn't recording.
+function RecordingDevice:getData() end
+
+---
+---Gets the name of the recording device.
+---
+---@return string name # The name of the device.
+function RecordingDevice:getName() end
+
+---
+---Gets the number of currently recorded samples.
+---
+---@return number samples # The number of samples that have been recorded so far.
+function RecordingDevice:getSampleCount() end
+
+---
+---Gets the number of samples per second currently being recorded.
+---
+---@return number rate # The number of samples being recorded per second (sample rate).
+function RecordingDevice:getSampleRate() end
+
+---
+---Gets whether the device is currently recording.
+---
+---@return boolean recording # True if the recording, false otherwise.
+function RecordingDevice:isRecording() end
+
+---
+---Begins recording audio using this device.
+---
+---@param samplecount number # The maximum number of samples to store in an internal ring buffer when recording. RecordingDevice:getData clears the internal buffer when called.
+---@param samplerate number # The number of samples per second to store when recording.
+---@param bitdepth number # The number of bits per sample.
+---@param channels number # Whether to record in mono or stereo. Most microphones don't support more than 1 channel.
+---@return boolean success # True if the device successfully began recording using the specified parameters, false if not.
+function RecordingDevice:start(samplecount, samplerate, bitdepth, channels) end
+
+---
+---Stops recording audio from this device. Any sound data currently in the device's buffer will be returned.
+---
+---@return love.audio.SoundData data # The sound data currently in the device's buffer, or nil if the device wasn't recording.
+function RecordingDevice:stop() end
+
+---@class love.audio.Source: love.audio.Object
+local Source = {}
+
+---
+---Creates an identical copy of the Source in the stopped state.
+---
+---Static Sources will use significantly less memory and take much less time to be created if Source:clone is used to create them instead of love.audio.newSource, so this method should be preferred when making multiple Sources which play the same sound.
+---
+---@return love.audio.Source source # The new identical copy of this Source.
+function Source:clone() end
+
+---
+---Gets a list of the Source's active effect names.
+---
+---@return table effects # A list of the source's active effect names.
+function Source:getActiveEffects() end
+
+---
+---Gets the amount of air absorption applied to the Source.
+---
+---By default the value is set to 0 which means that air absorption effects are disabled. A value of 1 will apply high frequency attenuation to the Source at a rate of 0.05 dB per meter.
+---
+---@return number amount # The amount of air absorption applied to the Source.
+function Source:getAirAbsorption() end
+
+---
+---Gets the reference and maximum attenuation distances of the Source. The values, combined with the current DistanceModel, affect how the Source's volume attenuates based on distance from the listener.
+---
+---@return number ref # The current reference attenuation distance. If the current DistanceModel is clamped, this is the minimum distance before the Source is no longer attenuated.
+---@return number max # The current maximum attenuation distance.
+function Source:getAttenuationDistances() end
+
+---
+---Gets the number of channels in the Source. Only 1-channel (mono) Sources can use directional and positional effects.
+---
+---@return number channels # 1 for mono, 2 for stereo.
+function Source:getChannelCount() end
+
+---
+---Gets the Source's directional volume cones. Together with Source:setDirection, the cone angles allow for the Source's volume to vary depending on its direction.
+---
+---@return number innerAngle # The inner angle from the Source's direction, in radians. The Source will play at normal volume if the listener is inside the cone defined by this angle.
+---@return number outerAngle # The outer angle from the Source's direction, in radians. The Source will play at a volume between the normal and outer volumes, if the listener is in between the cones defined by the inner and outer angles.
+---@return number outerVolume # The Source's volume when the listener is outside both the inner and outer cone angles.
+function Source:getCone() end
+
+---
+---Gets the direction of the Source.
+---
+---@return number x # The X part of the direction vector.
+---@return number y # The Y part of the direction vector.
+---@return number z # The Z part of the direction vector.
+function Source:getDirection() end
+
+---
+---Gets the duration of the Source. For streaming Sources it may not always be sample-accurate, and may return -1 if the duration cannot be determined at all.
+---
+---@param unit love.audio.TimeUnit # The time unit for the return value.
+---@return number duration # The duration of the Source, or -1 if it cannot be determined.
+function Source:getDuration(unit) end
+
+---
+---Gets the filter settings associated to a specific effect.
+---
+---This function returns nil if the effect was applied with no filter settings associated to it.
+---
+---@param name string # The name of the effect.
+---@param filtersettings table # An optional empty table that will be filled with the filter settings.
+---@return table filtersettings # The settings for the filter associated to this effect, or nil if the effect is not present in this Source or has no filter associated. The table has the following fields:
+function Source:getEffect(name, filtersettings) end
+
+---
+---Gets the filter settings currently applied to the Source.
+---
+---@return table settings # The filter settings to use for this Source, or nil if the Source has no active filter. The table has the following fields:
+function Source:getFilter() end
+
+---
+---Gets the number of free buffer slots in a queueable Source. If the queueable Source is playing, this value will increase up to the amount the Source was created with. If the queueable Source is stopped, it will process all of its internal buffers first, in which case this function will always return the amount it was created with.
+---
+---@return number buffers # How many more SoundData objects can be queued up.
+function Source:getFreeBufferCount() end
+
+---
+---Gets the current pitch of the Source.
+---
+---@return number pitch # The pitch, where 1.0 is normal.
+function Source:getPitch() end
+
+---
+---Gets the position of the Source.
+---
+---@return number x # The X position of the Source.
+---@return number y # The Y position of the Source.
+---@return number z # The Z position of the Source.
+function Source:getPosition() end
+
+---
+---Returns the rolloff factor of the source.
+---
+---@return number rolloff # The rolloff factor.
+function Source:getRolloff() end
+
+---
+---Gets the type of the Source.
+---
+---@return love.audio.SourceType sourcetype # The type of the source.
+function Source:getType() end
+
+---
+---Gets the velocity of the Source.
+---
+---@return number x # The X part of the velocity vector.
+---@return number y # The Y part of the velocity vector.
+---@return number z # The Z part of the velocity vector.
+function Source:getVelocity() end
+
+---
+---Gets the current volume of the Source.
+---
+---@return number volume # The volume of the Source, where 1.0 is normal volume.
+function Source:getVolume() end
+
+---
+---Returns the volume limits of the source.
+---
+---@return number min # The minimum volume.
+---@return number max # The maximum volume.
+function Source:getVolumeLimits() end
+
+---
+---Returns whether the Source will loop.
+---
+---@return boolean loop # True if the Source will loop, false otherwise.
+function Source:isLooping() end
+
+---
+---Returns whether the Source is playing.
+---
+---@return boolean playing # True if the Source is playing, false otherwise.
+function Source:isPlaying() end
+
+---
+---Gets whether the Source's position, velocity, direction, and cone angles are relative to the listener.
+---
+---@return boolean relative # True if the position, velocity, direction and cone angles are relative to the listener, false if they're absolute.
+function Source:isRelative() end
+
+---
+---Pauses the Source.
+---
+function Source:pause() end
+
+---
+---Starts playing the Source.
+---
+---@return boolean success # Whether the Source was able to successfully start playing.
+function Source:play() end
+
+---
+---Queues SoundData for playback in a queueable Source.
+---
+---This method requires the Source to be created via love.audio.newQueueableSource.
+---
+---@param sounddata love.audio.SoundData # The data to queue. The SoundData's sample rate, bit depth, and channel count must match the Source's.
+---@return boolean success # True if the data was successfully queued for playback, false if there were no available buffers to use for queueing.
+function Source:queue(sounddata) end
+
+---
+---Sets the currently playing position of the Source.
+---
+---@param offset number # The position to seek to.
+---@param unit love.audio.TimeUnit # The unit of the position value.
+function Source:seek(offset, unit) end
+
+---
+---Sets the amount of air absorption applied to the Source.
+---
+---By default the value is set to 0 which means that air absorption effects are disabled. A value of 1 will apply high frequency attenuation to the Source at a rate of 0.05 dB per meter.
+---
+---Air absorption can simulate sound transmission through foggy air, dry air, smoky atmosphere, etc. It can be used to simulate different atmospheric conditions within different locations in an area.
+---
+---@param amount number # The amount of air absorption applied to the Source. Must be between 0 and 10.
+function Source:setAirAbsorption(amount) end
+
+---
+---Sets the reference and maximum attenuation distances of the Source. The parameters, combined with the current DistanceModel, affect how the Source's volume attenuates based on distance.
+---
+---Distance attenuation is only applicable to Sources based on mono (rather than stereo) audio.
+---
+---@param ref number # The new reference attenuation distance. If the current DistanceModel is clamped, this is the minimum attenuation distance.
+---@param max number # The new maximum attenuation distance.
+function Source:setAttenuationDistances(ref, max) end
+
+---
+---Sets the Source's directional volume cones. Together with Source:setDirection, the cone angles allow for the Source's volume to vary depending on its direction.
+---
+---@param innerAngle number # The inner angle from the Source's direction, in radians. The Source will play at normal volume if the listener is inside the cone defined by this angle.
+---@param outerAngle number # The outer angle from the Source's direction, in radians. The Source will play at a volume between the normal and outer volumes, if the listener is in between the cones defined by the inner and outer angles.
+---@param outerVolume number # The Source's volume when the listener is outside both the inner and outer cone angles.
+function Source:setCone(innerAngle, outerAngle, outerVolume) end
+
+---
+---Sets the direction vector of the Source. A zero vector makes the source non-directional.
+---
+---@param x number # The X part of the direction vector.
+---@param y number # The Y part of the direction vector.
+---@param z number # The Z part of the direction vector.
+function Source:setDirection(x, y, z) end
+
+---
+---Applies an audio effect to the Source.
+---
+---The effect must have been previously defined using love.audio.setEffect.
+---
+---@param name string # The name of the effect previously set up with love.audio.setEffect.
+---@param enable boolean # If false and the given effect name was previously enabled on this Source, disables the effect.
+---@return boolean success # Whether the effect was successfully applied to this Source.
+function Source:setEffect(name, enable) end
+
+---
+---Sets a low-pass, high-pass, or band-pass filter to apply when playing the Source.
+---
+---@param settings table # The filter settings to use for this Source, with the following fields:
+---@return boolean success # Whether the filter was successfully applied to the Source.
+function Source:setFilter(settings) end
+
+---
+---Sets whether the Source should loop.
+---
+---@param loop boolean # True if the source should loop, false otherwise.
+function Source:setLooping(loop) end
+
+---
+---Sets the pitch of the Source.
+---
+---@param pitch number # Calculated with regard to 1 being the base pitch. Each reduction by 50 percent equals a pitch shift of -12 semitones (one octave reduction). Each doubling equals a pitch shift of 12 semitones (one octave increase). Zero is not a legal value.
+function Source:setPitch(pitch) end
+
+---
+---Sets the position of the Source. Please note that this only works for mono (i.e. non-stereo) sound files!
+---
+---@param x number # The X position of the Source.
+---@param y number # The Y position of the Source.
+---@param z number # The Z position of the Source.
+function Source:setPosition(x, y, z) end
+
+---
+---Sets whether the Source's position, velocity, direction, and cone angles are relative to the listener, or absolute.
+---
+---By default, all sources are absolute and therefore relative to the origin of love's coordinate system 0, 0. Only absolute sources are affected by the position of the listener. Please note that positional audio only works for mono (i.e. non-stereo) sources.
+---
+---@param enable boolean # True to make the position, velocity, direction and cone angles relative to the listener, false to make them absolute.
+function Source:setRelative(enable) end
+
+---
+---Sets the rolloff factor which affects the strength of the used distance attenuation.
+---
+---Extended information and detailed formulas can be found in the chapter '3.4. Attenuation By Distance' of OpenAL 1.1 specification.
+---
+---@param rolloff number # The new rolloff factor.
+function Source:setRolloff(rolloff) end
+
+---
+---Sets the velocity of the Source.
+---
+---This does '''not''' change the position of the Source, but lets the application know how it has to calculate the doppler effect.
+---
+---@param x number # The X part of the velocity vector.
+---@param y number # The Y part of the velocity vector.
+---@param z number # The Z part of the velocity vector.
+function Source:setVelocity(x, y, z) end
+
+---
+---Sets the current volume of the Source.
+---
+---@param volume number # The volume for a Source, where 1.0 is normal volume. Volume cannot be raised above 1.0.
+function Source:setVolume(volume) end
+
+---
+---Sets the volume limits of the source. The limits have to be numbers from 0 to 1.
+---
+---@param min number # The minimum volume.
+---@param max number # The maximum volume.
+function Source:setVolumeLimits(min, max) end
+
+---
+---Stops a Source.
+---
+function Source:stop() end
+
+---
+---Gets the currently playing position of the Source.
+---
+---@param unit love.audio.TimeUnit # The type of unit for the return value.
+---@return number position # The currently playing position of the Source.
+function Source:tell(unit) end
diff --git a/meta/3rd/love2d/library/love.data.lua b/meta/3rd/love2d/library/love.data.lua
index 7e7141a7..d9cfba5f 100644
--- a/meta/3rd/love2d/library/love.data.lua
+++ b/meta/3rd/love2d/library/love.data.lua
@@ -4,38 +4,38 @@ love.data = {}
---
---Compresses a string or data using a specific compression algorithm.
---
----@param container ContainerType # What type to return the compressed data as.
----@param format CompressedDataFormat # The format to use when compressing the string.
+---@param container love.data.ContainerType # What type to return the compressed data as.
+---@param format love.data.CompressedDataFormat # The format to use when compressing the string.
---@param rawstring string # The raw (un-compressed) string to compress.
---@param level number # The level of compression to use, between 0 and 9. -1 indicates the default level. The meaning of this argument depends on the compression format being used.
----@return CompressedData or string compressedData # CompressedData/string which contains the compressed version of rawstring.
+---@return love.data.CompressedData or string compressedData # CompressedData/string which contains the compressed version of rawstring.
function love.data.compress(container, format, rawstring, level) end
---
---Decode Data or a string from any of the EncodeFormats to Data or string.
---
----@param container ContainerType # What type to return the decoded data as.
----@param format EncodeFormat # The format of the input data.
+---@param container love.data.ContainerType # What type to return the decoded data as.
+---@param format love.data.EncodeFormat # The format of the input data.
---@param sourceString string # The raw (encoded) data to decode.
----@return ByteData or string decoded # ByteData/string which contains the decoded version of source.
+---@return love.data.ByteData or string decoded # ByteData/string which contains the decoded version of source.
function love.data.decode(container, format, sourceString) end
---
---Decompresses a CompressedData or previously compressed string or Data object.
---
----@param container ContainerType # What type to return the decompressed data as.
----@param compressedData CompressedData # The compressed data to decompress.
----@return Data or string decompressedData # Data/string containing the raw decompressed data.
+---@param container love.data.ContainerType # What type to return the decompressed data as.
+---@param compressedData love.data.CompressedData # The compressed data to decompress.
+---@return love.data.Data or string decompressedData # Data/string containing the raw decompressed data.
function love.data.decompress(container, compressedData) end
---
---Encode Data or a string to a Data or string in one of the EncodeFormats.
---
----@param container ContainerType # What type to return the encoded data as.
----@param format EncodeFormat # The format of the output data.
+---@param container love.data.ContainerType # What type to return the encoded data as.
+---@param format love.data.EncodeFormat # The format of the output data.
---@param sourceString string # The raw data to encode.
---@param linelength number # The maximum line length of the output. Only supported for base64, ignored if 0.
----@return ByteData or string encoded # ByteData/string which contains the encoded version of source.
+---@return love.data.ByteData or string encoded # ByteData/string which contains the encoded version of source.
function love.data.encode(container, format, sourceString, linelength) end
---
@@ -50,7 +50,7 @@ function love.data.getPackedSize(format) end
---
---Compute the message digest of a string using a specified hash algorithm.
---
----@param hashFunction HashFunction # Hash algorithm to use.
+---@param hashFunction love.data.HashFunction # Hash algorithm to use.
---@param string string # String to hash.
---@return string rawdigest # Raw message digest string.
function love.data.hash(hashFunction, string) end
@@ -61,16 +61,16 @@ function love.data.hash(hashFunction, string) end
---Data:getPointer along with LuaJIT's FFI can be used to manipulate the contents of the ByteData object after it has been created.
---
---@param datastring string # The byte string to copy.
----@return ByteData bytedata # The new Data object.
+---@return love.data.ByteData bytedata # The new Data object.
function love.data.newByteData(datastring) end
---
---Creates a new Data referencing a subsection of an existing Data object.
---
----@param data Data # The Data object to reference.
+---@param data love.data.Data # The Data object to reference.
---@param offset number # The offset of the subsection to reference, in bytes.
---@param size number # The size in bytes of the subsection to reference.
----@return Data view # The new Data view.
+---@return love.data.Data view # The new Data view.
function love.data.newDataView(data, offset, size) end
---
@@ -78,11 +78,11 @@ function love.data.newDataView(data, offset, size) end
---
---This function behaves the same as Lua 5.3's string.pack.
---
----@param container ContainerType # What type to return the encoded data as.
+---@param container love.data.ContainerType # What type to return the encoded data as.
---@param format string # A string determining how the values are packed. Follows the rules of Lua 5.3's string.pack format strings.
----@param v1 number or boolean or string # The first value (number, boolean, or string) to serialize.
----@param ... number or boolean or string # Additional values to serialize.
----@return Data or string data # Data/string which contains the serialized data.
+---@param v1 love.data.number or boolean or string # The first value (number, boolean, or string) to serialize.
+---@param ... love.data.number or boolean or string # Additional values to serialize.
+---@return love.data.Data or string data # Data/string which contains the serialized data.
function love.data.pack(container, format, v1, ...) end
---
@@ -93,7 +93,19 @@ function love.data.pack(container, format, v1, ...) end
---@param format string # A string determining how the values were packed. Follows the rules of Lua 5.3's string.pack format strings.
---@param datastring string # A string containing the packed (serialized) data.
---@param pos number # Where to start reading in the string. Negative values can be used to read relative from the end of the string.
----@return number or boolean or string v1 # The first value (number, boolean, or string) that was unpacked.
----@return number or boolean or string ... # Additional unpacked values.
+---@return love.data.number or boolean or string v1 # The first value (number, boolean, or string) that was unpacked.
+---@return love.data.number or boolean or string ... # Additional unpacked values.
---@return number index # The index of the first unread byte in the data string.
function love.data.unpack(format, datastring, pos) end
+
+---@class love.data.ByteData: love.data.Object, love.data.Data
+local ByteData = {}
+
+---@class love.data.CompressedData: love.data.Data, love.data.Object
+local CompressedData = {}
+
+---
+---Gets the compression format of the CompressedData.
+---
+---@return love.data.CompressedDataFormat format # The format of the CompressedData.
+function CompressedData:getFormat() end
diff --git a/meta/3rd/love2d/library/love.event.lua b/meta/3rd/love2d/library/love.event.lua
index 2cd65d46..83f9e536 100644
--- a/meta/3rd/love2d/library/love.event.lua
+++ b/meta/3rd/love2d/library/love.event.lua
@@ -28,14 +28,14 @@ function love.event.pump() end
---
---From 0.10.0 onwards, you may pass an arbitrary amount of arguments with this function, though the default callbacks don't ever use more than six.
---
----@param n Event # The name of the event.
----@param a Variant # First event argument.
----@param b Variant # Second event argument.
----@param c Variant # Third event argument.
----@param d Variant # Fourth event argument.
----@param e Variant # Fifth event argument.
----@param f Variant # Sixth event argument.
----@param ... Variant # Further event arguments may follow.
+---@param n love.event.Event # The name of the event.
+---@param a love.event.Variant # First event argument.
+---@param b love.event.Variant # Second event argument.
+---@param c love.event.Variant # Third event argument.
+---@param d love.event.Variant # Fourth event argument.
+---@param e love.event.Variant # Fifth event argument.
+---@param f love.event.Variant # Sixth event argument.
+---@param ... love.event.Variant # Further event arguments may follow.
function love.event.push(n, a, b, c, d, e, f, ...) end
---
@@ -49,12 +49,12 @@ function love.event.quit(exitstatus) end
---
---Like love.event.poll(), but blocks until there is an event in the queue.
---
----@return Event n # The name of event.
----@return Variant a # First event argument.
----@return Variant b # Second event argument.
----@return Variant c # Third event argument.
----@return Variant d # Fourth event argument.
----@return Variant e # Fifth event argument.
----@return Variant f # Sixth event argument.
----@return Variant ... # Further event arguments may follow.
+---@return love.event.Event n # The name of event.
+---@return love.event.Variant a # First event argument.
+---@return love.event.Variant b # Second event argument.
+---@return love.event.Variant c # Third event argument.
+---@return love.event.Variant d # Fourth event argument.
+---@return love.event.Variant e # Fifth event argument.
+---@return love.event.Variant f # Sixth event argument.
+---@return love.event.Variant ... # Further event arguments may follow.
function love.event.wait() end
diff --git a/meta/3rd/love2d/library/love.filesystem.lua b/meta/3rd/love2d/library/love.filesystem.lua
index 13b3b5c5..85ed717b 100644
--- a/meta/3rd/love2d/library/love.filesystem.lua
+++ b/meta/3rd/love2d/library/love.filesystem.lua
@@ -63,7 +63,7 @@ function love.filesystem.getIdentity() end
---Gets information about the specified file or directory.
---
---@param path string # The file or directory path to check.
----@param filtertype FileType # If supplied, this parameter causes getInfo to only return the info table if the item at the given path matches the specified file type.
+---@param filtertype love.filesystem.FileType # If supplied, this parameter causes getInfo to only return the info table if the item at the given path matches the specified file type.
---@return table info # A table containing information about the specified path, or nil if nothing exists at the path. The table contains the following fields:
function love.filesystem.getInfo(path, filtertype) end
@@ -170,7 +170,7 @@ function love.filesystem.mount(archive, mountpoint, appendToPath) end
---It needs to be opened before it can be accessed.
---
---@param filename string # The filename of the file.
----@return File file # The new File object.
+---@return love.filesystem.File file # The new File object.
function love.filesystem.newFile(filename) end
---
@@ -178,7 +178,7 @@ function love.filesystem.newFile(filename) end
---
---@param contents string # The contents of the file.
---@param name string # The name of the file.
----@return FileData data # Your new FileData.
+---@return love.filesystem.FileData data # Your new FileData.
function love.filesystem.newFileData(contents, name) end
---
@@ -255,3 +255,129 @@ function love.filesystem.unmount(archive) end
---@return boolean success # If the operation was successful.
---@return string message # Error message if operation was unsuccessful.
function love.filesystem.write(name, data, size) end
+
+---@class love.filesystem.DroppedFile: love.filesystem.File, love.filesystem.Object
+local DroppedFile = {}
+
+---@class love.filesystem.File: love.filesystem.Object
+local File = {}
+
+---
+---Closes a File.
+---
+---@return boolean success # Whether closing was successful.
+function File:close() end
+
+---
+---Flushes any buffered written data in the file to the disk.
+---
+---@return boolean success # Whether the file successfully flushed any buffered data to the disk.
+---@return string err # The error string, if an error occurred and the file could not be flushed.
+function File:flush() end
+
+---
+---Gets the buffer mode of a file.
+---
+---@return love.filesystem.BufferMode mode # The current buffer mode of the file.
+---@return number size # The maximum size in bytes of the file's buffer.
+function File:getBuffer() end
+
+---
+---Gets the filename that the File object was created with. If the file object originated from the love.filedropped callback, the filename will be the full platform-dependent file path.
+---
+---@return string filename # The filename of the File.
+function File:getFilename() end
+
+---
+---Gets the FileMode the file has been opened with.
+---
+---@return love.filesystem.FileMode mode # The mode this file has been opened with.
+function File:getMode() end
+
+---
+---Returns the file size.
+---
+---@return number size # The file size in bytes.
+function File:getSize() end
+
+---
+---Gets whether end-of-file has been reached.
+---
+---@return boolean eof # Whether EOF has been reached.
+function File:isEOF() end
+
+---
+---Gets whether the file is open.
+---
+---@return boolean open # True if the file is currently open, false otherwise.
+function File:isOpen() end
+
+---
+---Iterate over all the lines in a file.
+---
+---@return function iterator # The iterator (can be used in for loops).
+function File:lines() end
+
+---
+---Open the file for write, read or append.
+---
+---@param mode love.filesystem.FileMode # The mode to open the file in.
+---@return boolean ok # True on success, false otherwise.
+---@return string err # The error string if an error occurred.
+function File:open(mode) end
+
+---
+---Read a number of bytes from a file.
+---
+---@param bytes number # The number of bytes to read.
+---@return string contents # The contents of the read bytes.
+---@return number size # How many bytes have been read.
+function File:read(bytes) end
+
+---
+---Seek to a position in a file
+---
+---@param pos number # The position to seek to
+---@return boolean success # Whether the operation was successful
+function File:seek(pos) end
+
+---
+---Sets the buffer mode for a file opened for writing or appending. Files with buffering enabled will not write data to the disk until the buffer size limit is reached, depending on the buffer mode.
+---
+---File:flush will force any buffered data to be written to the disk.
+---
+---@param mode love.filesystem.BufferMode # The buffer mode to use.
+---@param size number # The maximum size in bytes of the file's buffer.
+---@return boolean success # Whether the buffer mode was successfully set.
+---@return string errorstr # The error string, if the buffer mode could not be set and an error occurred.
+function File:setBuffer(mode, size) end
+
+---
+---Returns the position in the file.
+---
+---@return number pos # The current position.
+function File:tell() end
+
+---
+---Write data to a file.
+---
+---@param data string # The string data to write.
+---@param size number # How many bytes to write.
+---@return boolean success # Whether the operation was successful.
+---@return string err # The error string if an error occurred.
+function File:write(data, size) end
+
+---@class love.filesystem.FileData: love.filesystem.Data, love.filesystem.Object
+local FileData = {}
+
+---
+---Gets the extension of the FileData.
+---
+---@return string ext # The extension of the file the FileData represents.
+function FileData:getExtension() end
+
+---
+---Gets the filename of the FileData.
+---
+---@return string name # The name of the file the FileData represents.
+function FileData:getFilename() end
diff --git a/meta/3rd/love2d/library/love.font.lua b/meta/3rd/love2d/library/love.font.lua
index 1c33106b..3037758d 100644
--- a/meta/3rd/love2d/library/love.font.lua
+++ b/meta/3rd/love2d/library/love.font.lua
@@ -4,41 +4,158 @@ love.font = {}
---
---Creates a new BMFont Rasterizer.
---
----@param imageData ImageData # The image data containing the drawable pictures of font glyphs.
+---@param imageData love.font.ImageData # The image data containing the drawable pictures of font glyphs.
---@param glyphs string # The sequence of glyphs in the ImageData.
---@param dpiscale number # DPI scale.
----@return Rasterizer rasterizer # The rasterizer.
+---@return love.font.Rasterizer rasterizer # The rasterizer.
function love.font.newBMFontRasterizer(imageData, glyphs, dpiscale) end
---
---Creates a new GlyphData.
---
----@param rasterizer Rasterizer # The Rasterizer containing the font.
+---@param rasterizer love.font.Rasterizer # The Rasterizer containing the font.
---@param glyph number # The character code of the glyph.
function love.font.newGlyphData(rasterizer, glyph) end
---
---Creates a new Image Rasterizer.
---
----@param imageData ImageData # Font image data.
+---@param imageData love.font.ImageData # Font image data.
---@param glyphs string # String containing font glyphs.
---@param extraSpacing number # Font extra spacing.
---@param dpiscale number # Font DPI scale.
----@return Rasterizer rasterizer # The rasterizer.
+---@return love.font.Rasterizer rasterizer # The rasterizer.
function love.font.newImageRasterizer(imageData, glyphs, extraSpacing, dpiscale) end
---
---Creates a new Rasterizer.
---
---@param filename string # The font file.
----@return Rasterizer rasterizer # The rasterizer.
+---@return love.font.Rasterizer rasterizer # The rasterizer.
function love.font.newRasterizer(filename) end
---
---Creates a new TrueType Rasterizer.
---
---@param size number # The font size.
----@param hinting HintingMode # True Type hinting mode.
+---@param hinting love.font.HintingMode # True Type hinting mode.
---@param dpiscale number # The font DPI scale.
----@return Rasterizer rasterizer # The rasterizer.
+---@return love.font.Rasterizer rasterizer # The rasterizer.
function love.font.newTrueTypeRasterizer(size, hinting, dpiscale) end
+
+---@class love.font.GlyphData: love.font.Data, love.font.Object
+local GlyphData = {}
+
+---
+---Gets glyph advance.
+---
+---@return number advance # Glyph advance.
+function GlyphData:getAdvance() end
+
+---
+---Gets glyph bearing.
+---
+---@return number bx # Glyph bearing X.
+---@return number by # Glyph bearing Y.
+function GlyphData:getBearing() end
+
+---
+---Gets glyph bounding box.
+---
+---@return number x # Glyph position x.
+---@return number y # Glyph position y.
+---@return number width # Glyph width.
+---@return number height # Glyph height.
+function GlyphData:getBoundingBox() end
+
+---
+---Gets glyph dimensions.
+---
+---@return number width # Glyph width.
+---@return number height # Glyph height.
+function GlyphData:getDimensions() end
+
+---
+---Gets glyph pixel format.
+---
+---@return love.font.PixelFormat format # Glyph pixel format.
+function GlyphData:getFormat() end
+
+---
+---Gets glyph number.
+---
+---@return number glyph # Glyph number.
+function GlyphData:getGlyph() end
+
+---
+---Gets glyph string.
+---
+---@return string glyph # Glyph string.
+function GlyphData:getGlyphString() end
+
+---
+---Gets glyph height.
+---
+---@return number height # Glyph height.
+function GlyphData:getHeight() end
+
+---
+---Gets glyph width.
+---
+---@return number width # Glyph width.
+function GlyphData:getWidth() end
+
+---@class love.font.Rasterizer: love.font.Object
+local Rasterizer = {}
+
+---
+---Gets font advance.
+---
+---@return number advance # Font advance.
+function Rasterizer:getAdvance() end
+
+---
+---Gets ascent height.
+---
+---@return number height # Ascent height.
+function Rasterizer:getAscent() end
+
+---
+---Gets descent height.
+---
+---@return number height # Descent height.
+function Rasterizer:getDescent() end
+
+---
+---Gets number of glyphs in font.
+---
+---@return number count # Glyphs count.
+function Rasterizer:getGlyphCount() end
+
+---
+---Gets glyph data of a specified glyph.
+---
+---@param glyph string # Glyph
+---@return love.font.GlyphData glyphData # Glyph data
+function Rasterizer:getGlyphData(glyph) end
+
+---
+---Gets font height.
+---
+---@return number height # Font height
+function Rasterizer:getHeight() end
+
+---
+---Gets line height of a font.
+---
+---@return number height # Line height of a font.
+function Rasterizer:getLineHeight() end
+
+---
+---Checks if font contains specified glyphs.
+---
+---@param glyph1 love.font.string or number # Glyph
+---@param glyph2 love.font.string or number # Glyph
+---@param ... love.font.string or number # Additional glyphs
+---@return boolean hasGlyphs # Whatever font contains specified glyphs.
+function Rasterizer:hasGlyphs(glyph1, glyph2, ...) end
diff --git a/meta/3rd/love2d/library/love.graphics.lua b/meta/3rd/love2d/library/love.graphics.lua
index b0bd6fc9..a73cdcd6 100644
--- a/meta/3rd/love2d/library/love.graphics.lua
+++ b/meta/3rd/love2d/library/love.graphics.lua
@@ -6,13 +6,13 @@ love.graphics = {}
---
---This effectively multiplies the existing coordinate transformation's matrix with the Transform object's internal matrix to produce the new coordinate transformation.
---
----@param transform Transform # The Transform object to apply to the current graphics coordinate transform.
+---@param transform love.graphics.Transform # The Transform object to apply to the current graphics coordinate transform.
function love.graphics.applyTransform(transform) end
---
---Draws a filled or unfilled arc at position (x, y). The arc is drawn from angle1 to angle2 in radians. The segments parameter determines how many segments are used to draw the arc. The more segments, the smoother the edge.
---
----@param drawmode DrawMode # How to draw the arc.
+---@param drawmode love.graphics.DrawMode # How to draw the arc.
---@param x number # The position of the center along x-axis.
---@param y number # The position of the center along y-axis.
---@param radius number # Radius of the arc.
@@ -32,7 +32,7 @@ function love.graphics.captureScreenshot(filename) end
---
---Draws a circle.
---
----@param mode DrawMode # How to draw the circle.
+---@param mode love.graphics.DrawMode # How to draw the circle.
---@param x number # The position of the center along x-axis.
---@param y number # The position of the center along y-axis.
---@param radius number # The radius of the circle.
@@ -75,7 +75,7 @@ function love.graphics.discard(discardcolor, discardstencil) end
---
---When using the default shader anything drawn with this function will be tinted according to the currently selected color. Set it to pure white to preserve the object's original colors.
---
----@param drawable Drawable # A drawable object.
+---@param drawable love.graphics.Drawable # A drawable object.
---@param x number # The position to draw the object (x-axis).
---@param y number # The position to draw the object (y-axis).
---@param r number # Orientation (radians).
@@ -94,7 +94,7 @@ function love.graphics.draw(drawable, x, y, r, sx, sy, ox, oy, kx, ky) end
---
---Instancing is not supported by some older GPUs that are only capable of using OpenGL ES 2 or OpenGL 2. Use love.graphics.getSupported to check.
---
----@param mesh Mesh # The mesh to render.
+---@param mesh love.graphics.Mesh # The mesh to render.
---@param instancecount number # The number of instances to render.
---@param x number # The position to draw the instances (x-axis).
---@param y number # The position to draw the instances (y-axis).
@@ -110,7 +110,7 @@ function love.graphics.drawInstanced(mesh, instancecount, x, y, r, sx, sy, ox, o
---
---Draws a layer of an Array Texture.
---
----@param texture Texture # The Array Texture to draw.
+---@param texture love.graphics.Texture # The Array Texture to draw.
---@param layerindex number # The index of the layer to use when drawing.
---@param x number # The position to draw the texture (x-axis).
---@param y number # The position to draw the texture (y-axis).
@@ -126,7 +126,7 @@ function love.graphics.drawLayer(texture, layerindex, x, y, r, sx, sy, ox, oy, k
---
---Draws an ellipse.
---
----@param mode DrawMode # How to draw the ellipse.
+---@param mode love.graphics.DrawMode # How to draw the ellipse.
---@param x number # The position of the center along x-axis.
---@param y number # The position of the center along y-axis.
---@param radiusx number # The radius of the ellipse along the x-axis (half the ellipse's width).
@@ -158,14 +158,14 @@ function love.graphics.getBackgroundColor() end
---
---Gets the blending mode.
---
----@return BlendMode mode # The current blend mode.
----@return BlendAlphaMode alphamode # The current blend alpha mode – it determines how the alpha of drawn objects affects blending.
+---@return love.graphics.BlendMode mode # The current blend mode.
+---@return love.graphics.BlendAlphaMode alphamode # The current blend alpha mode – it determines how the alpha of drawn objects affects blending.
function love.graphics.getBlendMode() end
---
---Gets the current target Canvas.
---
----@return Canvas canvas # The Canvas set by setCanvas. Returns nil if drawing to the real screen.
+---@return love.graphics.Canvas canvas # The Canvas set by setCanvas. Returns nil if drawing to the real screen.
function love.graphics.getCanvas() end
---
@@ -211,8 +211,8 @@ function love.graphics.getDPIScale() end
---
---Returns the default scaling filters used with Images, Canvases, and Fonts.
---
----@return FilterMode min # Filter mode used when scaling the image down.
----@return FilterMode mag # Filter mode used when scaling the image up.
+---@return love.graphics.FilterMode min # Filter mode used when scaling the image down.
+---@return love.graphics.FilterMode mag # Filter mode used when scaling the image up.
---@return number anisotropy # Maximum amount of Anisotropic Filtering used.
function love.graphics.getDefaultFilter() end
@@ -221,7 +221,7 @@ function love.graphics.getDefaultFilter() end
---
---This is low-level functionality designed for use with custom vertex shaders and Meshes with custom vertex attributes. No higher level APIs are provided to set the depth of 2D graphics such as shapes, lines, and Images.
---
----@return CompareMode comparemode # Depth comparison mode used for depth testing.
+---@return love.graphics.CompareMode comparemode # Depth comparison mode used for depth testing.
---@return boolean write # Whether to write update / write values to the depth buffer when rendering.
function love.graphics.getDepthMode() end
@@ -235,7 +235,7 @@ function love.graphics.getDimensions() end
---
---Gets the current Font object.
---
----@return Font font # The current Font. Automatically creates and sets the default font, if none is set yet.
+---@return love.graphics.Font font # The current Font. Automatically creates and sets the default font, if none is set yet.
function love.graphics.getFont() end
---
@@ -243,7 +243,7 @@ function love.graphics.getFont() end
---
---This is designed for use in combination with Mesh face culling. Other love.graphics shapes, lines, and sprites are not guaranteed to have a specific winding order to their internal vertices.
---
----@return VertexWinding winding # The winding mode being used. The default winding is counterclockwise ('ccw').
+---@return love.graphics.VertexWinding winding # The winding mode being used. The default winding is counterclockwise ('ccw').
function love.graphics.getFrontFaceWinding() end
---
@@ -261,13 +261,13 @@ function love.graphics.getImageFormats() end
---
---Gets the line join style.
---
----@return LineJoin join # The LineJoin style.
+---@return love.graphics.LineJoin join # The LineJoin style.
function love.graphics.getLineJoin() end
---
---Gets the line style.
---
----@return LineStyle style # The current line style.
+---@return love.graphics.LineStyle style # The current line style.
function love.graphics.getLineStyle() end
---
@@ -281,7 +281,7 @@ function love.graphics.getLineWidth() end
---
---Mesh face culling is designed for use with low level custom hardware-accelerated 3D rendering via custom vertex attributes on Meshes, custom vertex shaders, and depth testing with a depth buffer.
---
----@return CullMode mode # The Mesh face culling mode in use (whether to render everything, cull back-facing triangles, or cull front-facing triangles).
+---@return love.graphics.CullMode mode # The Mesh face culling mode in use (whether to render everything, cull back-facing triangles, or cull front-facing triangles).
function love.graphics.getMeshCullMode() end
---
@@ -336,7 +336,7 @@ function love.graphics.getScissor() end
---
---Gets the current Shader. Returns nil if none is set.
---
----@return Shader shader # The currently active Shader, or nil if none is set.
+---@return love.graphics.Shader shader # The currently active Shader, or nil if none is set.
function love.graphics.getShader() end
---
@@ -358,7 +358,7 @@ function love.graphics.getStats() end
---
---Each Canvas has its own per-pixel stencil values.
---
----@return CompareMode comparemode # The type of comparison that is made for each pixel. Will be 'always' if stencil testing is disabled.
+---@return love.graphics.CompareMode comparemode # The type of comparison that is made for each pixel. Will be 'always' if stencil testing is disabled.
---@return number comparevalue # The value used when comparing with the stencil value of each pixel.
function love.graphics.getStencilTest() end
@@ -454,13 +454,13 @@ function love.graphics.line(x1, y1, x2, y2, ...) end
---
---@param slices table # A table containing filepaths to images (or File, FileData, ImageData, or CompressedImageData objects), in an array. Each sub-image must have the same dimensions. A table of tables can also be given, where each sub-table contains all mipmap levels for the slice index of that sub-table.
---@param settings table # Optional table of settings to configure the array image, containing the following fields:
----@return Image image # An Array Image object.
+---@return love.graphics.Image image # An Array Image object.
function love.graphics.newArrayImage(slices, settings) end
---
---Creates a new Canvas object for offscreen rendering.
---
----@return Canvas canvas # A new Canvas with dimensions equal to the window's size in pixels.
+---@return love.graphics.Canvas canvas # A new Canvas with dimensions equal to the window's size in pixels.
function love.graphics.newCanvas() end
---
@@ -510,7 +510,7 @@ function love.graphics.newCanvas() end
---
---@param filename string # The filepath to a cubemap image file (or a File, FileData, or ImageData).
---@param settings table # Optional table of settings to configure the cubemap image, containing the following fields:
----@return Image image # An cubemap Image object.
+---@return love.graphics.Image image # An cubemap Image object.
function love.graphics.newCubeImage(filename, settings) end
---
@@ -519,14 +519,14 @@ function love.graphics.newCubeImage(filename, settings) end
---All variants which accept a filename can also accept a Data object instead.
---
---@param filename string # The filepath to the BMFont or TrueType font file.
----@return Font font # A Font object which can be used to draw text on screen.
+---@return love.graphics.Font font # A Font object which can be used to draw text on screen.
function love.graphics.newFont(filename) end
---
---Creates a new Image from a filepath, FileData, an ImageData, or a CompressedImageData, and optionally generates or specifies mipmaps for the image.
---
---@param filename string # The filepath to the image file.
----@return Image image # An Image object which can be drawn on screen.
+---@return love.graphics.Image image # An Image object which can be drawn on screen.
function love.graphics.newImage(filename) end
---
@@ -536,7 +536,7 @@ function love.graphics.newImage(filename) end
---
---@param filename string # The filepath to the image file.
---@param glyphs string # A string of the characters in the image in order from left to right.
----@return Font font # A Font object which can be used to draw text on screen.
+---@return love.graphics.Font font # A Font object which can be used to draw text on screen.
function love.graphics.newImageFont(filename, glyphs) end
---
@@ -547,17 +547,17 @@ function love.graphics.newImageFont(filename, glyphs) end
---In versions prior to 11.0, color and byte component values were within the range of 0 to 255 instead of 0 to 1.
---
---@param vertices table # The table filled with vertex information tables for each vertex as follows:
----@param mode MeshDrawMode # How the vertices are used when drawing. The default mode 'fan' is sufficient for simple convex polygons.
----@param usage SpriteBatchUsage # The expected usage of the Mesh. The specified usage mode affects the Mesh's memory usage and performance.
----@return Mesh mesh # The new mesh.
+---@param mode love.graphics.MeshDrawMode # How the vertices are used when drawing. The default mode 'fan' is sufficient for simple convex polygons.
+---@param usage love.graphics.SpriteBatchUsage # The expected usage of the Mesh. The specified usage mode affects the Mesh's memory usage and performance.
+---@return love.graphics.Mesh mesh # The new mesh.
function love.graphics.newMesh(vertices, mode, usage) end
---
---Creates a new ParticleSystem.
---
----@param image Image # The image to use.
+---@param image love.graphics.Image # The image to use.
---@param buffer number # The max number of particles at the same time.
----@return ParticleSystem system # A new ParticleSystem.
+---@return love.graphics.ParticleSystem system # A new ParticleSystem.
function love.graphics.newParticleSystem(image, buffer) end
---
@@ -571,7 +571,7 @@ function love.graphics.newParticleSystem(image, buffer) end
---@param height number # The height of the Quad in the Image. (Must be greater than 0.)
---@param sw number # The reference width, the width of the Image. (Must be greater than 0.)
---@param sh number # The reference height, the height of the Image. (Must be greater than 0.)
----@return Quad quad # The new Quad.
+---@return love.graphics.Quad quad # The new Quad.
function love.graphics.newQuad(x, y, width, height, sw, sh) end
---
@@ -580,30 +580,30 @@ function love.graphics.newQuad(x, y, width, height, sw, sh) end
---Shaders are small programs which are run on the graphics card when drawing. Vertex shaders are run once for each vertex (for example, an image has 4 vertices - one at each corner. A Mesh might have many more.) Pixel shaders are run once for each pixel on the screen which the drawn object touches. Pixel shader code is executed after all the object's vertices have been processed by the vertex shader.
---
---@param code string # The pixel shader or vertex shader code, or a filename pointing to a file with the code.
----@return Shader shader # A Shader object for use in drawing operations.
+---@return love.graphics.Shader shader # A Shader object for use in drawing operations.
function love.graphics.newShader(code) end
---
---Creates a new SpriteBatch object.
---
----@param image Image # The Image to use for the sprites.
+---@param image love.graphics.Image # The Image to use for the sprites.
---@param maxsprites number # The maximum number of sprites that the SpriteBatch can contain at any given time. Since version 11.0, additional sprites added past this number will automatically grow the spritebatch.
----@return SpriteBatch spriteBatch # The new SpriteBatch.
+---@return love.graphics.SpriteBatch spriteBatch # The new SpriteBatch.
function love.graphics.newSpriteBatch(image, maxsprites) end
---
---Creates a new drawable Text object.
---
----@param font Font # The font to use for the text.
+---@param font love.graphics.Font # The font to use for the text.
---@param textstring string # The initial string of text that the new Text object will contain. May be nil.
----@return Text text # The new drawable Text object.
+---@return love.graphics.Text text # The new drawable Text object.
function love.graphics.newText(font, textstring) end
---
---Creates a new drawable Video. Currently only Ogg Theora video files are supported.
---
---@param filename string # The file path to the Ogg Theora video file.
----@return Video video # A new Video.
+---@return love.graphics.Video video # A new Video.
function love.graphics.newVideo(filename) end
---
@@ -619,7 +619,7 @@ function love.graphics.newVideo(filename) end
---
---@param layers table # A table containing filepaths to images (or File, FileData, ImageData, or CompressedImageData objects), in an array. A table of tables can also be given, where each sub-table represents a single mipmap level and contains all layers for that mipmap.
---@param settings table # Optional table of settings to configure the volume image, containing the following fields:
----@return Image image # A volume Image object.
+---@return love.graphics.Image image # A volume Image object.
function love.graphics.newVolumeImage(layers, settings) end
---
@@ -642,7 +642,7 @@ function love.graphics.points(x, y, ...) end
---
---Following the mode argument, this function can accept multiple numeric arguments or a single table of numeric arguments. In either case the arguments are interpreted as alternating x and y coordinates of the polygon's vertices.
---
----@param mode DrawMode # How to draw the polygon.
+---@param mode love.graphics.DrawMode # How to draw the polygon.
---@param ... number # The vertices of the polygon.
function love.graphics.polygon(mode, ...) end
@@ -696,7 +696,7 @@ function love.graphics.print(text, x, y, r, sx, sy, ox, oy, kx, ky) end
---@param x number # The position on the x-axis.
---@param y number # The position on the y-axis.
---@param limit number # Wrap the line after this many horizontal pixels.
----@param align AlignMode # The alignment.
+---@param align love.graphics.AlignMode # The alignment.
---@param r number # Orientation (radians).
---@param sx number # Scale factor (x-axis).
---@param sy number # Scale factor (y-axis).
@@ -716,7 +716,7 @@ function love.graphics.push() end
---
---Draws a rectangle.
---
----@param mode DrawMode # How to draw the rectangle.
+---@param mode love.graphics.DrawMode # How to draw the rectangle.
---@param x number # The position of top-left corner along the x-axis.
---@param y number # The position of top-left corner along the y-axis.
---@param width number # Width of the rectangle.
@@ -726,7 +726,7 @@ function love.graphics.rectangle(mode, x, y, width, height) end
---
---Replaces the current coordinate transformation with the given Transform object.
---
----@param transform Transform # The Transform object to replace the current graphics coordinate transform with.
+---@param transform love.graphics.Transform # The Transform object to replace the current graphics coordinate transform with.
function love.graphics.replaceTransform(transform) end
---
@@ -771,13 +771,13 @@ function love.graphics.setBackgroundColor(red, green, blue, alpha) end
---
---Sets the blending mode.
---
----@param mode BlendMode # The blend mode to use.
+---@param mode love.graphics.BlendMode # The blend mode to use.
function love.graphics.setBlendMode(mode) end
---
---Captures drawing operations to a Canvas.
---
----@param canvas Canvas # The new target.
+---@param canvas love.graphics.Canvas # The new target.
---@param mipmap number # The mipmap level to render to, for Canvases with mipmaps.
function love.graphics.setCanvas(canvas, mipmap) end
@@ -804,8 +804,8 @@ function love.graphics.setColorMask(red, green, blue, alpha) end
---
---Sets the default scaling filters used with Images, Canvases, and Fonts.
---
----@param min FilterMode # Filter mode used when scaling the image down.
----@param mag FilterMode # Filter mode used when scaling the image up.
+---@param min love.graphics.FilterMode # Filter mode used when scaling the image down.
+---@param mag love.graphics.FilterMode # Filter mode used when scaling the image up.
---@param anisotropy number # Maximum amount of Anisotropic Filtering used.
function love.graphics.setDefaultFilter(min, mag, anisotropy) end
@@ -814,7 +814,7 @@ function love.graphics.setDefaultFilter(min, mag, anisotropy) end
---
---This is low-level functionality designed for use with custom vertex shaders and Meshes with custom vertex attributes. No higher level APIs are provided to set the depth of 2D graphics such as shapes, lines, and Images.
---
----@param comparemode CompareMode # Depth comparison mode used for depth testing.
+---@param comparemode love.graphics.CompareMode # Depth comparison mode used for depth testing.
---@param write boolean # Whether to write update / write values to the depth buffer when rendering.
function love.graphics.setDepthMode(comparemode, write) end
@@ -823,7 +823,7 @@ function love.graphics.setDepthMode(comparemode, write) end
---
---It's recommended that Font objects are created with love.graphics.newFont in the loading stage and then passed to this function in the drawing stage.
---
----@param font Font # The Font object to use.
+---@param font love.graphics.Font # The Font object to use.
function love.graphics.setFont(font) end
---
@@ -831,19 +831,19 @@ function love.graphics.setFont(font) end
---
---This is designed for use in combination with Mesh face culling. Other love.graphics shapes, lines, and sprites are not guaranteed to have a specific winding order to their internal vertices.
---
----@param winding VertexWinding # The winding mode to use. The default winding is counterclockwise ('ccw').
+---@param winding love.graphics.VertexWinding # The winding mode to use. The default winding is counterclockwise ('ccw').
function love.graphics.setFrontFaceWinding(winding) end
---
---Sets the line join style. See LineJoin for the possible options.
---
----@param join LineJoin # The LineJoin to use.
+---@param join love.graphics.LineJoin # The LineJoin to use.
function love.graphics.setLineJoin(join) end
---
---Sets the line style.
---
----@param style LineStyle # The LineStyle to use. Line styles include smooth and rough.
+---@param style love.graphics.LineStyle # The LineStyle to use. Line styles include smooth and rough.
function love.graphics.setLineStyle(style) end
---
@@ -859,14 +859,14 @@ function love.graphics.setLineWidth(width) end
---
---By default, both front- and back-facing triangles in Meshes are rendered.
---
----@param mode CullMode # The Mesh face culling mode to use (whether to render everything, cull back-facing triangles, or cull front-facing triangles).
+---@param mode love.graphics.CullMode # The Mesh face culling mode to use (whether to render everything, cull back-facing triangles, or cull front-facing triangles).
function love.graphics.setMeshCullMode(mode) end
---
---Creates and sets a new Font.
---
---@param size number # The size of the font.
----@return Font font # The new font.
+---@return love.graphics.Font font # The new font.
function love.graphics.setNewFont(size) end
---
@@ -891,7 +891,7 @@ function love.graphics.setScissor(x, y, width, height) end
---
---Sets or resets a Shader as the current pixel effect or vertex shaders. All drawing operations until the next ''love.graphics.setShader'' will be drawn using the Shader object specified.
---
----@param shader Shader # The new shader.
+---@param shader love.graphics.Shader # The new shader.
function love.graphics.setShader(shader) end
---
@@ -899,7 +899,7 @@ function love.graphics.setShader(shader) end
---
---When stencil testing is enabled, the geometry of everything that is drawn afterward will be clipped / stencilled out based on a comparison between the arguments of this function and the stencil value of each pixel that the geometry touches. The stencil values of pixels are affected via love.graphics.stencil.
---
----@param comparemode CompareMode # The type of comparison to make for each pixel.
+---@param comparemode love.graphics.CompareMode # The type of comparison to make for each pixel.
---@param comparevalue number # The value to use when comparing with the stencil value of each pixel. Must be between 0 and 255.
function love.graphics.setStencilTest(comparemode, comparevalue) end
@@ -924,7 +924,7 @@ function love.graphics.shear(kx, ky) end
---Stencil values are integers within the range of 255.
---
---@param stencilfunction function # Function which draws geometry. The stencil values of pixels, rather than the color of each pixel, will be affected by the geometry.
----@param action StencilAction # How to modify any stencil values of pixels that are touched by what's drawn in the stencil function.
+---@param action love.graphics.StencilAction # How to modify any stencil values of pixels that are touched by what's drawn in the stencil function.
---@param value number # The new stencil value to use for pixels if the 'replace' stencil action is used. Has no effect with other stencil actions. Must be between 0 and 255.
---@param keepvalues boolean # True to preserve old stencil values of pixels, false to re-set every pixel's stencil value to 0 before executing the stencil function. love.graphics.clear will also re-set all stencil values.
function love.graphics.stencil(stencilfunction, action, value, keepvalues) end
@@ -963,3 +963,1372 @@ function love.graphics.translate(dx, dy) end
---@return boolean status # true if specified shader code doesn't contain any errors. false otherwise.
---@return string message # Reason why shader code validation failed (or nil if validation succeded).
function love.graphics.validateShader(gles, code) end
+
+---@class love.graphics.Canvas: love.graphics.Texture, love.graphics.Drawable, love.graphics.Object
+local Canvas = {}
+
+---
+---Generates mipmaps for the Canvas, based on the contents of the highest-resolution mipmap level.
+---
+---The Canvas must be created with mipmaps set to a MipmapMode other than 'none' for this function to work. It should only be called while the Canvas is not the active render target.
+---
+---If the mipmap mode is set to 'auto', this function is automatically called inside love.graphics.setCanvas when switching from this Canvas to another Canvas or to the main screen.
+---
+function Canvas:generateMipmaps() end
+
+---
+---Gets the number of multisample antialiasing (MSAA) samples used when drawing to the Canvas.
+---
+---This may be different than the number used as an argument to love.graphics.newCanvas if the system running LÖVE doesn't support that number.
+---
+---@return number samples # The number of multisample antialiasing samples used by the canvas when drawing to it.
+function Canvas:getMSAA() end
+
+---
+---Gets the MipmapMode this Canvas was created with.
+---
+---@return love.graphics.MipmapMode mode # The mipmap mode this Canvas was created with.
+function Canvas:getMipmapMode() end
+
+---
+---Generates ImageData from the contents of the Canvas.
+---
+---@return love.graphics.ImageData data # The new ImageData made from the Canvas' contents.
+function Canvas:newImageData() end
+
+---
+---Render to the Canvas using a function.
+---
+---This is a shortcut to love.graphics.setCanvas:
+---
+---canvas:renderTo( func )
+---
+---is the same as
+---
+---love.graphics.setCanvas( canvas )
+---
+---func()
+---
+---love.graphics.setCanvas()
+---
+---@param func function # A function performing drawing operations.
+function Canvas:renderTo(func) end
+
+---@class love.graphics.Drawable: love.graphics.Object
+local Drawable = {}
+
+---@class love.graphics.Font: love.graphics.Object
+local Font = {}
+
+---
+---Gets the ascent of the Font.
+---
+---The ascent spans the distance between the baseline and the top of the glyph that reaches farthest from the baseline.
+---
+---@return number ascent # The ascent of the Font in pixels.
+function Font:getAscent() end
+
+---
+---Gets the baseline of the Font.
+---
+---Most scripts share the notion of a baseline: an imaginary horizontal line on which characters rest. In some scripts, parts of glyphs lie below the baseline.
+---
+---@return number baseline # The baseline of the Font in pixels.
+function Font:getBaseline() end
+
+---
+---Gets the DPI scale factor of the Font.
+---
+---The DPI scale factor represents relative pixel density. A DPI scale factor of 2 means the font's glyphs have twice the pixel density in each dimension (4 times as many pixels in the same area) compared to a font with a DPI scale factor of 1.
+---
+---The font size of TrueType fonts is scaled internally by the font's specified DPI scale factor. By default, LÖVE uses the screen's DPI scale factor when creating TrueType fonts.
+---
+---@return number dpiscale # The DPI scale factor of the Font.
+function Font:getDPIScale() end
+
+---
+---Gets the descent of the Font.
+---
+---The descent spans the distance between the baseline and the lowest descending glyph in a typeface.
+---
+---@return number descent # The descent of the Font in pixels.
+function Font:getDescent() end
+
+---
+---Gets the filter mode for a font.
+---
+---@return love.graphics.FilterMode min # Filter mode used when minifying the font.
+---@return love.graphics.FilterMode mag # Filter mode used when magnifying the font.
+---@return number anisotropy # Maximum amount of anisotropic filtering used.
+function Font:getFilter() end
+
+---
+---Gets the height of the Font.
+---
+---The height of the font is the size including any spacing; the height which it will need.
+---
+---@return number height # The height of the Font in pixels.
+function Font:getHeight() end
+
+---
+---Gets the line height.
+---
+---This will be the value previously set by Font:setLineHeight, or 1.0 by default.
+---
+---@return number height # The current line height.
+function Font:getLineHeight() end
+
+---
+---Determines the maximum width (accounting for newlines) taken by the given string.
+---
+---@param text string # A string.
+---@return number width # The width of the text.
+function Font:getWidth(text) end
+
+---
+---Gets formatting information for text, given a wrap limit.
+---
+---This function accounts for newlines correctly (i.e. '\n').
+---
+---@param text string # The text that will be wrapped.
+---@param wraplimit number # The maximum width in pixels of each line that ''text'' is allowed before wrapping.
+---@return number width # The maximum width of the wrapped text.
+---@return table wrappedtext # A sequence containing each line of text that was wrapped.
+function Font:getWrap(text, wraplimit) end
+
+---
+---Gets whether the Font can render a character or string.
+---
+---@param text string # A UTF-8 encoded unicode string.
+---@return boolean hasglyph # Whether the font can render all the UTF-8 characters in the string.
+function Font:hasGlyphs(text) end
+
+---
+---Sets the fallback fonts. When the Font doesn't contain a glyph, it will substitute the glyph from the next subsequent fallback Fonts. This is akin to setting a 'font stack' in Cascading Style Sheets (CSS).
+---
+---@param fallbackfont1 love.graphics.Font # The first fallback Font to use.
+---@param ... love.graphics.Font # Additional fallback Fonts.
+function Font:setFallbacks(fallbackfont1, ...) end
+
+---
+---Sets the filter mode for a font.
+---
+---@param min love.graphics.FilterMode # How to scale a font down.
+---@param mag love.graphics.FilterMode # How to scale a font up.
+---@param anisotropy number # Maximum amount of anisotropic filtering used.
+function Font:setFilter(min, mag, anisotropy) end
+
+---
+---Sets the line height.
+---
+---When rendering the font in lines the actual height will be determined by the line height multiplied by the height of the font. The default is 1.0.
+---
+---@param height number # The new line height.
+function Font:setLineHeight(height) end
+
+---@class love.graphics.Image: love.graphics.Texture, love.graphics.Drawable, love.graphics.Object
+local Image = {}
+
+---
+---Gets the flags used when the image was created.
+---
+---@return table flags # A table with ImageFlag keys.
+function Image:getFlags() end
+
+---
+---Gets whether the Image was created from CompressedData.
+---
+---Compressed images take up less space in VRAM, and drawing a compressed image will generally be more efficient than drawing one created from raw pixel data.
+---
+---@return boolean compressed # Whether the Image is stored as a compressed texture on the GPU.
+function Image:isCompressed() end
+
+---
+---Replace the contents of an Image.
+---
+---@param data love.graphics.ImageData # The new ImageData to replace the contents with.
+---@param slice number # Which cubemap face, array index, or volume layer to replace, if applicable.
+---@param mipmap number # The mimap level to replace, if the Image has mipmaps.
+---@param x number # The x-offset in pixels from the top-left of the image to replace. The given ImageData's width plus this value must not be greater than the pixel width of the Image's specified mipmap level.
+---@param y number # The y-offset in pixels from the top-left of the image to replace. The given ImageData's height plus this value must not be greater than the pixel height of the Image's specified mipmap level.
+---@param reloadmipmaps boolean # Whether to generate new mipmaps after replacing the Image's pixels. True by default if the Image was created with automatically generated mipmaps, false by default otherwise.
+function Image:replacePixels(data, slice, mipmap, x, y, reloadmipmaps) end
+
+---@class love.graphics.Mesh: love.graphics.Drawable, love.graphics.Object
+local Mesh = {}
+
+---
+---Attaches a vertex attribute from a different Mesh onto this Mesh, for use when drawing. This can be used to share vertex attribute data between several different Meshes.
+---
+---@param name string # The name of the vertex attribute to attach.
+---@param mesh love.graphics.Mesh # The Mesh to get the vertex attribute from.
+function Mesh:attachAttribute(name, mesh) end
+
+---
+---Attaches a vertex attribute from a different Mesh onto this Mesh, for use when drawing. This can be used to share vertex attribute data between several different Meshes.
+---
+---@param name string # The name of the vertex attribute to attach.
+---@param mesh love.graphics.Mesh # The Mesh to get the vertex attribute from.
+function Mesh:attachAttribute(name, mesh) end
+
+---
+---Removes a previously attached vertex attribute from this Mesh.
+---
+---@param name string # The name of the attached vertex attribute to detach.
+---@return boolean success # Whether the attribute was successfully detached.
+function Mesh:detachAttribute(name) end
+
+---
+---Gets the mode used when drawing the Mesh.
+---
+---@return love.graphics.MeshDrawMode mode # The mode used when drawing the Mesh.
+function Mesh:getDrawMode() end
+
+---
+---Gets the range of vertices used when drawing the Mesh.
+---
+---@return number min # The index of the first vertex used when drawing, or the index of the first value in the vertex map used if one is set for this Mesh.
+---@return number max # The index of the last vertex used when drawing, or the index of the last value in the vertex map used if one is set for this Mesh.
+function Mesh:getDrawRange() end
+
+---
+---Gets the texture (Image or Canvas) used when drawing the Mesh.
+---
+---@return love.graphics.Texture texture # The Image or Canvas to texture the Mesh with when drawing, or nil if none is set.
+function Mesh:getTexture() end
+
+---
+---Gets the properties of a vertex in the Mesh.
+---
+---In versions prior to 11.0, color and byte component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param index number # The one-based index of the vertex you want to retrieve the information for.
+---@return number attributecomponent # The first component of the first vertex attribute in the specified vertex.
+---@return number ... # Additional components of all vertex attributes in the specified vertex.
+function Mesh:getVertex(index) end
+
+---
+---Gets the properties of a specific attribute within a vertex in the Mesh.
+---
+---Meshes without a custom vertex format specified in love.graphics.newMesh have position as their first attribute, texture coordinates as their second attribute, and color as their third attribute.
+---
+---@param vertexindex number # The index of the the vertex you want to retrieve the attribute for (one-based).
+---@param attributeindex number # The index of the attribute within the vertex to be retrieved (one-based).
+---@return number value1 # The value of the first component of the attribute.
+---@return number value2 # The value of the second component of the attribute.
+---@return number ... # Any additional vertex attribute components.
+function Mesh:getVertexAttribute(vertexindex, attributeindex) end
+
+---
+---Gets the total number of vertices in the Mesh.
+---
+---@return number count # The total number of vertices in the mesh.
+function Mesh:getVertexCount() end
+
+---
+---Gets the vertex format that the Mesh was created with.
+---
+---@return table format # The vertex format of the Mesh, which is a table containing tables for each vertex attribute the Mesh was created with, in the form of {attribute, ...}.
+function Mesh:getVertexFormat() end
+
+---
+---Gets the vertex map for the Mesh. The vertex map describes the order in which the vertices are used when the Mesh is drawn. The vertices, vertex map, and mesh draw mode work together to determine what exactly is displayed on the screen.
+---
+---If no vertex map has been set previously via Mesh:setVertexMap, then this function will return nil in LÖVE 0.10.0+, or an empty table in 0.9.2 and older.
+---
+---@return table map # A table containing the list of vertex indices used when drawing.
+function Mesh:getVertexMap() end
+
+---
+---Gets whether a specific vertex attribute in the Mesh is enabled. Vertex data from disabled attributes is not used when drawing the Mesh.
+---
+---@param name string # The name of the vertex attribute to be checked.
+---@return boolean enabled # Whether the vertex attribute is used when drawing this Mesh.
+function Mesh:isAttributeEnabled(name) end
+
+---
+---Enables or disables a specific vertex attribute in the Mesh. Vertex data from disabled attributes is not used when drawing the Mesh.
+---
+---@param name string # The name of the vertex attribute to enable or disable.
+---@param enable boolean # Whether the vertex attribute is used when drawing this Mesh.
+function Mesh:setAttributeEnabled(name, enable) end
+
+---
+---Sets the mode used when drawing the Mesh.
+---
+---@param mode love.graphics.MeshDrawMode # The mode to use when drawing the Mesh.
+function Mesh:setDrawMode(mode) end
+
+---
+---Restricts the drawn vertices of the Mesh to a subset of the total.
+---
+---@param start number # The index of the first vertex to use when drawing, or the index of the first value in the vertex map to use if one is set for this Mesh.
+---@param count number # The number of vertices to use when drawing, or number of values in the vertex map to use if one is set for this Mesh.
+function Mesh:setDrawRange(start, count) end
+
+---
+---Sets the texture (Image or Canvas) used when drawing the Mesh.
+---
+---@param texture love.graphics.Texture # The Image or Canvas to texture the Mesh with when drawing.
+function Mesh:setTexture(texture) end
+
+---
+---Sets the properties of a vertex in the Mesh.
+---
+---In versions prior to 11.0, color and byte component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param index number # The index of the the vertex you want to modify (one-based).
+---@param attributecomponent number # The first component of the first vertex attribute in the specified vertex.
+---@param ... number # Additional components of all vertex attributes in the specified vertex.
+function Mesh:setVertex(index, attributecomponent, ...) end
+
+---
+---Sets the properties of a specific attribute within a vertex in the Mesh.
+---
+---Meshes without a custom vertex format specified in love.graphics.newMesh have position as their first attribute, texture coordinates as their second attribute, and color as their third attribute.
+---
+---@param vertexindex number # The index of the the vertex to be modified (one-based).
+---@param attributeindex number # The index of the attribute within the vertex to be modified (one-based).
+---@param value1 number # The new value for the first component of the attribute.
+---@param value2 number # The new value for the second component of the attribute.
+---@param ... number # Any additional vertex attribute components.
+function Mesh:setVertexAttribute(vertexindex, attributeindex, value1, value2, ...) end
+
+---
+---Sets the vertex map for the Mesh. The vertex map describes the order in which the vertices are used when the Mesh is drawn. The vertices, vertex map, and mesh draw mode work together to determine what exactly is displayed on the screen.
+---
+---The vertex map allows you to re-order or reuse vertices when drawing without changing the actual vertex parameters or duplicating vertices. It is especially useful when combined with different Mesh Draw Modes.
+---
+---@param map table # A table containing a list of vertex indices to use when drawing. Values must be in the range of Mesh:getVertexCount().
+function Mesh:setVertexMap(map) end
+
+---
+---Replaces a range of vertices in the Mesh with new ones. The total number of vertices in a Mesh cannot be changed after it has been created. This is often more efficient than calling Mesh:setVertex in a loop.
+---
+---@param vertices table # The table filled with vertex information tables for each vertex, in the form of {vertex, ...} where each vertex is a table in the form of {attributecomponent, ...}.
+---@param startvertex number # The index of the first vertex to replace.
+function Mesh:setVertices(vertices, startvertex) end
+
+---@class love.graphics.ParticleSystem: love.graphics.Drawable, love.graphics.Object
+local ParticleSystem = {}
+
+---
+---Creates an identical copy of the ParticleSystem in the stopped state.
+---
+---@return love.graphics.ParticleSystem particlesystem # The new identical copy of this ParticleSystem.
+function ParticleSystem:clone() end
+
+---
+---Emits a burst of particles from the particle emitter.
+---
+---@param numparticles number # The amount of particles to emit. The number of emitted particles will be truncated if the particle system's max buffer size is reached.
+function ParticleSystem:emit(numparticles) end
+
+---
+---Gets the maximum number of particles the ParticleSystem can have at once.
+---
+---@return number size # The maximum number of particles.
+function ParticleSystem:getBufferSize() end
+
+---
+---Gets the series of colors applied to the particle sprite.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@return number r1 # First color, red component (0-1).
+---@return number g1 # First color, green component (0-1).
+---@return number b1 # First color, blue component (0-1).
+---@return number a1 # First color, alpha component (0-1).
+---@return number r2 # Second color, red component (0-1).
+---@return number g2 # Second color, green component (0-1).
+---@return number b2 # Second color, blue component (0-1).
+---@return number a2 # Second color, alpha component (0-1).
+---@return number r8 # Eighth color, red component (0-1).
+---@return number g8 # Eighth color, green component (0-1).
+---@return number b8 # Eighth color, blue component (0-1).
+---@return number a8 # Eighth color, alpha component (0-1).
+function ParticleSystem:getColors() end
+
+---
+---Gets the number of particles that are currently in the system.
+---
+---@return number count # The current number of live particles.
+function ParticleSystem:getCount() end
+
+---
+---Gets the direction of the particle emitter (in radians).
+---
+---@return number direction # The direction of the emitter (radians).
+function ParticleSystem:getDirection() end
+
+---
+---Gets the area-based spawn parameters for the particles.
+---
+---@return love.graphics.AreaSpreadDistribution distribution # The type of distribution for new particles.
+---@return number dx # The maximum spawn distance from the emitter along the x-axis for uniform distribution, or the standard deviation along the x-axis for normal distribution.
+---@return number dy # The maximum spawn distance from the emitter along the y-axis for uniform distribution, or the standard deviation along the y-axis for normal distribution.
+---@return number angle # The angle in radians of the emission area.
+---@return boolean directionRelativeToCenter # True if newly spawned particles will be oriented relative to the center of the emission area, false otherwise.
+function ParticleSystem:getEmissionArea() end
+
+---
+---Gets the amount of particles emitted per second.
+---
+---@return number rate # The amount of particles per second.
+function ParticleSystem:getEmissionRate() end
+
+---
+---Gets how long the particle system will emit particles (if -1 then it emits particles forever).
+---
+---@return number life # The lifetime of the emitter (in seconds).
+function ParticleSystem:getEmitterLifetime() end
+
+---
+---Gets the mode used when the ParticleSystem adds new particles.
+---
+---@return love.graphics.ParticleInsertMode mode # The mode used when the ParticleSystem adds new particles.
+function ParticleSystem:getInsertMode() end
+
+---
+---Gets the linear acceleration (acceleration along the x and y axes) for particles.
+---
+---Every particle created will accelerate along the x and y axes between xmin,ymin and xmax,ymax.
+---
+---@return number xmin # The minimum acceleration along the x axis.
+---@return number ymin # The minimum acceleration along the y axis.
+---@return number xmax # The maximum acceleration along the x axis.
+---@return number ymax # The maximum acceleration along the y axis.
+function ParticleSystem:getLinearAcceleration() end
+
+---
+---Gets the amount of linear damping (constant deceleration) for particles.
+---
+---@return number min # The minimum amount of linear damping applied to particles.
+---@return number max # The maximum amount of linear damping applied to particles.
+function ParticleSystem:getLinearDamping() end
+
+---
+---Gets the particle image's draw offset.
+---
+---@return number ox # The x coordinate of the particle image's draw offset.
+---@return number oy # The y coordinate of the particle image's draw offset.
+function ParticleSystem:getOffset() end
+
+---
+---Gets the lifetime of the particles.
+---
+---@return number min # The minimum life of the particles (in seconds).
+---@return number max # The maximum life of the particles (in seconds).
+function ParticleSystem:getParticleLifetime() end
+
+---
+---Gets the position of the emitter.
+---
+---@return number x # Position along x-axis.
+---@return number y # Position along y-axis.
+function ParticleSystem:getPosition() end
+
+---
+---Gets the series of Quads used for the particle sprites.
+---
+---@return table quads # A table containing the Quads used.
+function ParticleSystem:getQuads() end
+
+---
+---Gets the radial acceleration (away from the emitter).
+---
+---@return number min # The minimum acceleration.
+---@return number max # The maximum acceleration.
+function ParticleSystem:getRadialAcceleration() end
+
+---
+---Gets the rotation of the image upon particle creation (in radians).
+---
+---@return number min # The minimum initial angle (radians).
+---@return number max # The maximum initial angle (radians).
+function ParticleSystem:getRotation() end
+
+---
+---Gets the amount of size variation (0 meaning no variation and 1 meaning full variation between start and end).
+---
+---@return number variation # The amount of variation (0 meaning no variation and 1 meaning full variation between start and end).
+function ParticleSystem:getSizeVariation() end
+
+---
+---Gets the series of sizes by which the sprite is scaled. 1.0 is normal size. The particle system will interpolate between each size evenly over the particle's lifetime.
+---
+---@return number size1 # The first size.
+---@return number size2 # The second size.
+---@return number size8 # The eighth size.
+function ParticleSystem:getSizes() end
+
+---
+---Gets the speed of the particles.
+---
+---@return number min # The minimum linear speed of the particles.
+---@return number max # The maximum linear speed of the particles.
+function ParticleSystem:getSpeed() end
+
+---
+---Gets the spin of the sprite.
+---
+---@return number min # The minimum spin (radians per second).
+---@return number max # The maximum spin (radians per second).
+---@return number variation # The degree of variation (0 meaning no variation and 1 meaning full variation between start and end).
+function ParticleSystem:getSpin() end
+
+---
+---Gets the amount of spin variation (0 meaning no variation and 1 meaning full variation between start and end).
+---
+---@return number variation # The amount of variation (0 meaning no variation and 1 meaning full variation between start and end).
+function ParticleSystem:getSpinVariation() end
+
+---
+---Gets the amount of directional spread of the particle emitter (in radians).
+---
+---@return number spread # The spread of the emitter (radians).
+function ParticleSystem:getSpread() end
+
+---
+---Gets the tangential acceleration (acceleration perpendicular to the particle's direction).
+---
+---@return number min # The minimum acceleration.
+---@return number max # The maximum acceleration.
+function ParticleSystem:getTangentialAcceleration() end
+
+---
+---Gets the texture (Image or Canvas) used for the particles.
+---
+---@return love.graphics.Texture texture # The Image or Canvas used for the particles.
+function ParticleSystem:getTexture() end
+
+---
+---Gets whether particle angles and rotations are relative to their velocities. If enabled, particles are aligned to the angle of their velocities and rotate relative to that angle.
+---
+---@return boolean enable # True if relative particle rotation is enabled, false if it's disabled.
+function ParticleSystem:hasRelativeRotation() end
+
+---
+---Checks whether the particle system is actively emitting particles.
+---
+---@return boolean active # True if system is active, false otherwise.
+function ParticleSystem:isActive() end
+
+---
+---Checks whether the particle system is paused.
+---
+---@return boolean paused # True if system is paused, false otherwise.
+function ParticleSystem:isPaused() end
+
+---
+---Checks whether the particle system is stopped.
+---
+---@return boolean stopped # True if system is stopped, false otherwise.
+function ParticleSystem:isStopped() end
+
+---
+---Moves the position of the emitter. This results in smoother particle spawning behaviour than if ParticleSystem:setPosition is used every frame.
+---
+---@param x number # Position along x-axis.
+---@param y number # Position along y-axis.
+function ParticleSystem:moveTo(x, y) end
+
+---
+---Pauses the particle emitter.
+---
+function ParticleSystem:pause() end
+
+---
+---Resets the particle emitter, removing any existing particles and resetting the lifetime counter.
+---
+function ParticleSystem:reset() end
+
+---
+---Sets the size of the buffer (the max allowed amount of particles in the system).
+---
+---@param size number # The buffer size.
+function ParticleSystem:setBufferSize(size) end
+
+---
+---Sets a series of colors to apply to the particle sprite. The particle system will interpolate between each color evenly over the particle's lifetime.
+---
+---Arguments can be passed in groups of four, representing the components of the desired RGBA value, or as tables of RGBA component values, with a default alpha value of 1 if only three values are given. At least one color must be specified. A maximum of eight may be used.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param r1 number # First color, red component (0-1).
+---@param g1 number # First color, green component (0-1).
+---@param b1 number # First color, blue component (0-1).
+---@param a1 number # First color, alpha component (0-1).
+---@param r2 number # Second color, red component (0-1).
+---@param g2 number # Second color, green component (0-1).
+---@param b2 number # Second color, blue component (0-1).
+---@param a2 number # Second color, alpha component (0-1).
+---@param r8 number # Eighth color, red component (0-1).
+---@param g8 number # Eighth color, green component (0-1).
+---@param b8 number # Eighth color, blue component (0-1).
+---@param a8 number # Eighth color, alpha component (0-1).
+function ParticleSystem:setColors(r1, g1, b1, a1, r2, g2, b2, a2, r8, g8, b8, a8) end
+
+---
+---Sets the direction the particles will be emitted in.
+---
+---@param direction number # The direction of the particles (in radians).
+function ParticleSystem:setDirection(direction) end
+
+---
+---Sets area-based spawn parameters for the particles. Newly created particles will spawn in an area around the emitter based on the parameters to this function.
+---
+---@param distribution love.graphics.AreaSpreadDistribution # The type of distribution for new particles.
+---@param dx number # The maximum spawn distance from the emitter along the x-axis for uniform distribution, or the standard deviation along the x-axis for normal distribution.
+---@param dy number # The maximum spawn distance from the emitter along the y-axis for uniform distribution, or the standard deviation along the y-axis for normal distribution.
+---@param angle number # The angle in radians of the emission area.
+---@param directionRelativeToCenter boolean # True if newly spawned particles will be oriented relative to the center of the emission area, false otherwise.
+function ParticleSystem:setEmissionArea(distribution, dx, dy, angle, directionRelativeToCenter) end
+
+---
+---Sets the amount of particles emitted per second.
+---
+---@param rate number # The amount of particles per second.
+function ParticleSystem:setEmissionRate(rate) end
+
+---
+---Sets how long the particle system should emit particles (if -1 then it emits particles forever).
+---
+---@param life number # The lifetime of the emitter (in seconds).
+function ParticleSystem:setEmitterLifetime(life) end
+
+---
+---Sets the mode to use when the ParticleSystem adds new particles.
+---
+---@param mode love.graphics.ParticleInsertMode # The mode to use when the ParticleSystem adds new particles.
+function ParticleSystem:setInsertMode(mode) end
+
+---
+---Sets the linear acceleration (acceleration along the x and y axes) for particles.
+---
+---Every particle created will accelerate along the x and y axes between xmin,ymin and xmax,ymax.
+---
+---@param xmin number # The minimum acceleration along the x axis.
+---@param ymin number # The minimum acceleration along the y axis.
+---@param xmax number # The maximum acceleration along the x axis.
+---@param ymax number # The maximum acceleration along the y axis.
+function ParticleSystem:setLinearAcceleration(xmin, ymin, xmax, ymax) end
+
+---
+---Sets the amount of linear damping (constant deceleration) for particles.
+---
+---@param min number # The minimum amount of linear damping applied to particles.
+---@param max number # The maximum amount of linear damping applied to particles.
+function ParticleSystem:setLinearDamping(min, max) end
+
+---
+---Set the offset position which the particle sprite is rotated around.
+---
+---If this function is not used, the particles rotate around their center.
+---
+---@param x number # The x coordinate of the rotation offset.
+---@param y number # The y coordinate of the rotation offset.
+function ParticleSystem:setOffset(x, y) end
+
+---
+---Sets the lifetime of the particles.
+---
+---@param min number # The minimum life of the particles (in seconds).
+---@param max number # The maximum life of the particles (in seconds).
+function ParticleSystem:setParticleLifetime(min, max) end
+
+---
+---Sets the position of the emitter.
+---
+---@param x number # Position along x-axis.
+---@param y number # Position along y-axis.
+function ParticleSystem:setPosition(x, y) end
+
+---
+---Sets a series of Quads to use for the particle sprites. Particles will choose a Quad from the list based on the particle's current lifetime, allowing for the use of animated sprite sheets with ParticleSystems.
+---
+---@param quad1 love.graphics.Quad # The first Quad to use.
+---@param quad2 love.graphics.Quad # The second Quad to use.
+function ParticleSystem:setQuads(quad1, quad2) end
+
+---
+---Set the radial acceleration (away from the emitter).
+---
+---@param min number # The minimum acceleration.
+---@param max number # The maximum acceleration.
+function ParticleSystem:setRadialAcceleration(min, max) end
+
+---
+---Sets whether particle angles and rotations are relative to their velocities. If enabled, particles are aligned to the angle of their velocities and rotate relative to that angle.
+---
+---@param enable boolean # True to enable relative particle rotation, false to disable it.
+function ParticleSystem:setRelativeRotation(enable) end
+
+---
+---Sets the rotation of the image upon particle creation (in radians).
+---
+---@param min number # The minimum initial angle (radians).
+---@param max number # The maximum initial angle (radians).
+function ParticleSystem:setRotation(min, max) end
+
+---
+---Sets the amount of size variation (0 meaning no variation and 1 meaning full variation between start and end).
+---
+---@param variation number # The amount of variation (0 meaning no variation and 1 meaning full variation between start and end).
+function ParticleSystem:setSizeVariation(variation) end
+
+---
+---Sets a series of sizes by which to scale a particle sprite. 1.0 is normal size. The particle system will interpolate between each size evenly over the particle's lifetime.
+---
+---At least one size must be specified. A maximum of eight may be used.
+---
+---@param size1 number # The first size.
+---@param size2 number # The second size.
+---@param size8 number # The eighth size.
+function ParticleSystem:setSizes(size1, size2, size8) end
+
+---
+---Sets the speed of the particles.
+---
+---@param min number # The minimum linear speed of the particles.
+---@param max number # The maximum linear speed of the particles.
+function ParticleSystem:setSpeed(min, max) end
+
+---
+---Sets the spin of the sprite.
+---
+---@param min number # The minimum spin (radians per second).
+---@param max number # The maximum spin (radians per second).
+function ParticleSystem:setSpin(min, max) end
+
+---
+---Sets the amount of spin variation (0 meaning no variation and 1 meaning full variation between start and end).
+---
+---@param variation number # The amount of variation (0 meaning no variation and 1 meaning full variation between start and end).
+function ParticleSystem:setSpinVariation(variation) end
+
+---
+---Sets the amount of spread for the system.
+---
+---@param spread number # The amount of spread (radians).
+function ParticleSystem:setSpread(spread) end
+
+---
+---Sets the tangential acceleration (acceleration perpendicular to the particle's direction).
+---
+---@param min number # The minimum acceleration.
+---@param max number # The maximum acceleration.
+function ParticleSystem:setTangentialAcceleration(min, max) end
+
+---
+---Sets the texture (Image or Canvas) to be used for the particles.
+---
+---@param texture love.graphics.Texture # An Image or Canvas to use for the particles.
+function ParticleSystem:setTexture(texture) end
+
+---
+---Starts the particle emitter.
+---
+function ParticleSystem:start() end
+
+---
+---Stops the particle emitter, resetting the lifetime counter.
+---
+function ParticleSystem:stop() end
+
+---
+---Updates the particle system; moving, creating and killing particles.
+---
+---@param dt number # The time (seconds) since last frame.
+function ParticleSystem:update(dt) end
+
+---@class love.graphics.Quad: love.graphics.Object
+local Quad = {}
+
+---
+---Gets reference texture dimensions initially specified in love.graphics.newQuad.
+---
+---@return number sw # The Texture width used by the Quad.
+---@return number sh # The Texture height used by the Quad.
+function Quad:getTextureDimensions() end
+
+---
+---Gets the current viewport of this Quad.
+---
+---@return number x # The top-left corner along the x-axis.
+---@return number y # The top-left corner along the y-axis.
+---@return number w # The width of the viewport.
+---@return number h # The height of the viewport.
+function Quad:getViewport() end
+
+---
+---Sets the texture coordinates according to a viewport.
+---
+---@param x number # The top-left corner along the x-axis.
+---@param y number # The top-left corner along the y-axis.
+---@param w number # The width of the viewport.
+---@param h number # The height of the viewport.
+---@param sw number # The reference width, the width of the Image. (Must be greater than 0.)
+---@param sh number # The reference height, the height of the Image. (Must be greater than 0.)
+function Quad:setViewport(x, y, w, h, sw, sh) end
+
+---@class love.graphics.Shader: love.graphics.Object
+local Shader = {}
+
+---
+---Returns any warning and error messages from compiling the shader code. This can be used for debugging your shaders if there's anything the graphics hardware doesn't like.
+---
+---@return string warnings # Warning and error messages (if any).
+function Shader:getWarnings() end
+
+---
+---Gets whether a uniform / extern variable exists in the Shader.
+---
+---If a graphics driver's shader compiler determines that a uniform / extern variable doesn't affect the final output of the shader, it may optimize the variable out. This function will return false in that case.
+---
+---@param name string # The name of the uniform variable.
+---@return boolean hasuniform # Whether the uniform exists in the shader and affects its final output.
+function Shader:hasUniform(name) end
+
+---
+---Sends one or more values to a special (''uniform'') variable inside the shader. Uniform variables have to be marked using the ''uniform'' or ''extern'' keyword, e.g.
+---
+---uniform float time; // 'float' is the typical number type used in GLSL shaders.
+---
+---uniform float varsvec2 light_pos;
+---
+---uniform vec4 colors[4;
+---
+---The corresponding send calls would be
+---
+---shader:send('time', t)
+---
+---shader:send('vars',a,b)
+---
+---shader:send('light_pos', {light_x, light_y})
+---
+---shader:send('colors', {r1, g1, b1, a1}, {r2, g2, b2, a2}, {r3, g3, b3, a3}, {r4, g4, b4, a4})
+---
+---Uniform / extern variables are read-only in the shader code and remain constant until modified by a Shader:send call. Uniform variables can be accessed in both the Vertex and Pixel components of a shader, as long as the variable is declared in each.
+---
+---@param name string # Name of the number to send to the shader.
+---@param number number # Number to send to store in the uniform variable.
+---@param ... number # Additional numbers to send if the uniform variable is an array.
+function Shader:send(name, number, ...) end
+
+---
+---Sends one or more colors to a special (''extern'' / ''uniform'') vec3 or vec4 variable inside the shader. The color components must be in the range of 1. The colors are gamma-corrected if global gamma-correction is enabled.
+---
+---Extern variables must be marked using the ''extern'' keyword, e.g.
+---
+---extern vec4 Color;
+---
+---The corresponding sendColor call would be
+---
+---shader:sendColor('Color', {r, g, b, a})
+---
+---Extern variables can be accessed in both the Vertex and Pixel stages of a shader, as long as the variable is declared in each.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param name string # The name of the color extern variable to send to in the shader.
+---@param color table # A table with red, green, blue, and optional alpha color components in the range of 1 to send to the extern as a vector.
+---@param ... table # Additional colors to send in case the extern is an array. All colors need to be of the same size (e.g. only vec3's).
+function Shader:sendColor(name, color, ...) end
+
+---@class love.graphics.SpriteBatch: love.graphics.Drawable, love.graphics.Object
+local SpriteBatch = {}
+
+---
+---Adds a sprite to the batch. Sprites are drawn in the order they are added.
+---
+---@param x number # The position to draw the object (x-axis).
+---@param y number # The position to draw the object (y-axis).
+---@param r number # Orientation (radians).
+---@param sx number # Scale factor (x-axis).
+---@param sy number # Scale factor (y-axis).
+---@param ox number # Origin offset (x-axis).
+---@param oy number # Origin offset (y-axis).
+---@param kx number # Shear factor (x-axis).
+---@param ky number # Shear factor (y-axis).
+---@return number id # An identifier for the added sprite.
+function SpriteBatch:add(x, y, r, sx, sy, ox, oy, kx, ky) end
+
+---
+---Adds a sprite to a batch created with an Array Texture.
+---
+---@param layerindex number # The index of the layer to use for this sprite.
+---@param x number # The position to draw the sprite (x-axis).
+---@param y number # The position to draw the sprite (y-axis).
+---@param r number # Orientation (radians).
+---@param sx number # Scale factor (x-axis).
+---@param sy number # Scale factor (y-axis).
+---@param ox number # Origin offset (x-axis).
+---@param oy number # Origin offset (y-axis).
+---@param kx number # Shearing factor (x-axis).
+---@param ky number # Shearing factor (y-axis).
+---@return number spriteindex # The index of the added sprite, for use with SpriteBatch:set or SpriteBatch:setLayer.
+function SpriteBatch:addLayer(layerindex, x, y, r, sx, sy, ox, oy, kx, ky) end
+
+---
+---Attaches a per-vertex attribute from a Mesh onto this SpriteBatch, for use when drawing. This can be combined with a Shader to augment a SpriteBatch with per-vertex or additional per-sprite information instead of just having per-sprite colors.
+---
+---Each sprite in a SpriteBatch has 4 vertices in the following order: top-left, bottom-left, top-right, bottom-right. The index returned by SpriteBatch:add (and used by SpriteBatch:set) can used to determine the first vertex of a specific sprite with the formula 1 + 4 * ( id - 1 ).
+---
+---@param name string # The name of the vertex attribute to attach.
+---@param mesh love.graphics.Mesh # The Mesh to get the vertex attribute from.
+function SpriteBatch:attachAttribute(name, mesh) end
+
+---
+---Removes all sprites from the buffer.
+---
+function SpriteBatch:clear() end
+
+---
+---Immediately sends all new and modified sprite data in the batch to the graphics card.
+---
+---Normally it isn't necessary to call this method as love.graphics.draw(spritebatch, ...) will do it automatically if needed, but explicitly using SpriteBatch:flush gives more control over when the work happens.
+---
+---If this method is used, it generally shouldn't be called more than once (at most) between love.graphics.draw(spritebatch, ...) calls.
+---
+function SpriteBatch:flush() end
+
+---
+---Gets the maximum number of sprites the SpriteBatch can hold.
+---
+---@return number size # The maximum number of sprites the batch can hold.
+function SpriteBatch:getBufferSize() end
+
+---
+---Gets the color that will be used for the next add and set operations.
+---
+---If no color has been set with SpriteBatch:setColor or the current SpriteBatch color has been cleared, this method will return nil.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@return number r # The red component (0-1).
+---@return number g # The green component (0-1).
+---@return number b # The blue component (0-1).
+---@return number a # The alpha component (0-1).
+function SpriteBatch:getColor() end
+
+---
+---Gets the number of sprites currently in the SpriteBatch.
+---
+---@return number count # The number of sprites currently in the batch.
+function SpriteBatch:getCount() end
+
+---
+---Gets the texture (Image or Canvas) used by the SpriteBatch.
+---
+---@return love.graphics.Texture texture # The Image or Canvas used by the SpriteBatch.
+function SpriteBatch:getTexture() end
+
+---
+---Changes a sprite in the batch. This requires the sprite index returned by SpriteBatch:add or SpriteBatch:addLayer.
+---
+---@param spriteindex number # The index of the sprite that will be changed.
+---@param x number # The position to draw the object (x-axis).
+---@param y number # The position to draw the object (y-axis).
+---@param r number # Orientation (radians).
+---@param sx number # Scale factor (x-axis).
+---@param sy number # Scale factor (y-axis).
+---@param ox number # Origin offset (x-axis).
+---@param oy number # Origin offset (y-axis).
+---@param kx number # Shear factor (x-axis).
+---@param ky number # Shear factor (y-axis).
+function SpriteBatch:set(spriteindex, x, y, r, sx, sy, ox, oy, kx, ky) end
+
+---
+---Sets the color that will be used for the next add and set operations. Calling the function without arguments will disable all per-sprite colors for the SpriteBatch.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---In version 0.9.2 and older, the global color set with love.graphics.setColor will not work on the SpriteBatch if any of the sprites has its own color.
+---
+---@param r number # The amount of red.
+---@param g number # The amount of green.
+---@param b number # The amount of blue.
+---@param a number # The amount of alpha.
+function SpriteBatch:setColor(r, g, b, a) end
+
+---
+---Restricts the drawn sprites in the SpriteBatch to a subset of the total.
+---
+---@param start number # The index of the first sprite to draw. Index 1 corresponds to the first sprite added with SpriteBatch:add.
+---@param count number # The number of sprites to draw.
+function SpriteBatch:setDrawRange(start, count) end
+
+---
+---Changes a sprite previously added with add or addLayer, in a batch created with an Array Texture.
+---
+---@param spriteindex number # The index of the existing sprite to replace.
+---@param layerindex number # The index of the layer in the Array Texture to use for this sprite.
+---@param x number # The position to draw the sprite (x-axis).
+---@param y number # The position to draw the sprite (y-axis).
+---@param r number # Orientation (radians).
+---@param sx number # Scale factor (x-axis).
+---@param sy number # Scale factor (y-axis).
+---@param ox number # Origin offset (x-axis).
+---@param oy number # Origin offset (y-axis).
+---@param kx number # Shearing factor (x-axis).
+---@param ky number # Shearing factor (y-axis).
+function SpriteBatch:setLayer(spriteindex, layerindex, x, y, r, sx, sy, ox, oy, kx, ky) end
+
+---
+---Sets the texture (Image or Canvas) used for the sprites in the batch, when drawing.
+---
+---@param texture love.graphics.Texture # The new Image or Canvas to use for the sprites in the batch.
+function SpriteBatch:setTexture(texture) end
+
+---@class love.graphics.Text: love.graphics.Drawable, love.graphics.Object
+local Text = {}
+
+---
+---Adds additional colored text to the Text object at the specified position.
+---
+---@param textstring string # The text to add to the object.
+---@param x number # The position of the new text on the x-axis.
+---@param y number # The position of the new text on the y-axis.
+---@param angle number # The orientation of the new text in radians.
+---@param sx number # Scale factor on the x-axis.
+---@param sy number # Scale factor on the y-axis.
+---@param ox number # Origin offset on the x-axis.
+---@param oy number # Origin offset on the y-axis.
+---@param kx number # Shearing / skew factor on the x-axis.
+---@param ky number # Shearing / skew factor on the y-axis.
+---@return number index # An index number that can be used with Text:getWidth or Text:getHeight.
+function Text:add(textstring, x, y, angle, sx, sy, ox, oy, kx, ky) end
+
+---
+---Adds additional formatted / colored text to the Text object at the specified position.
+---
+---The word wrap limit is applied before any scaling, rotation, and other coordinate transformations. Therefore the amount of text per line stays constant given the same wrap limit, even if the scale arguments change.
+---
+---@param textstring string # The text to add to the object.
+---@param wraplimit number # The maximum width in pixels of the text before it gets automatically wrapped to a new line.
+---@param align love.graphics.AlignMode # The alignment of the text.
+---@param x number # The position of the new text (x-axis).
+---@param y number # The position of the new text (y-axis).
+---@param angle number # Orientation (radians).
+---@param sx number # Scale factor (x-axis).
+---@param sy number # Scale factor (y-axis).
+---@param ox number # Origin offset (x-axis).
+---@param oy number # Origin offset (y-axis).
+---@param kx number # Shearing / skew factor (x-axis).
+---@param ky number # Shearing / skew factor (y-axis).
+---@return number index # An index number that can be used with Text:getWidth or Text:getHeight.
+function Text:addf(textstring, wraplimit, align, x, y, angle, sx, sy, ox, oy, kx, ky) end
+
+---
+---Clears the contents of the Text object.
+---
+function Text:clear() end
+
+---
+---Gets the width and height of the text in pixels.
+---
+---@return number width # The width of the text. If multiple sub-strings have been added with Text:add, the width of the last sub-string is returned.
+---@return number height # The height of the text. If multiple sub-strings have been added with Text:add, the height of the last sub-string is returned.
+function Text:getDimensions() end
+
+---
+---Gets the Font used with the Text object.
+---
+---@return love.graphics.Font font # The font used with this Text object.
+function Text:getFont() end
+
+---
+---Gets the height of the text in pixels.
+---
+---@return number height # The height of the text. If multiple sub-strings have been added with Text:add, the height of the last sub-string is returned.
+function Text:getHeight() end
+
+---
+---Gets the width of the text in pixels.
+---
+---@return number width # The width of the text. If multiple sub-strings have been added with Text:add, the width of the last sub-string is returned.
+function Text:getWidth() end
+
+---
+---Replaces the contents of the Text object with a new unformatted string.
+---
+---@param textstring string # The new string of text to use.
+function Text:set(textstring) end
+
+---
+---Replaces the Font used with the text.
+---
+---@param font love.graphics.Font # The new font to use with this Text object.
+function Text:setFont(font) end
+
+---
+---Replaces the contents of the Text object with a new formatted string.
+---
+---@param textstring string # The new string of text to use.
+---@param wraplimit number # The maximum width in pixels of the text before it gets automatically wrapped to a new line.
+---@param align love.graphics.AlignMode # The alignment of the text.
+function Text:setf(textstring, wraplimit, align) end
+
+---@class love.graphics.Texture: love.graphics.Drawable, love.graphics.Object
+local Texture = {}
+
+---
+---Gets the DPI scale factor of the Texture.
+---
+---The DPI scale factor represents relative pixel density. A DPI scale factor of 2 means the texture has twice the pixel density in each dimension (4 times as many pixels in the same area) compared to a texture with a DPI scale factor of 1.
+---
+---For example, a texture with pixel dimensions of 100x100 with a DPI scale factor of 2 will be drawn as if it was 50x50. This is useful with high-dpi / retina displays to easily allow swapping out higher or lower pixel density Images and Canvases without needing any extra manual scaling logic.
+---
+---@return number dpiscale # The DPI scale factor of the Texture.
+function Texture:getDPIScale() end
+
+---
+---Gets the depth of a Volume Texture. Returns 1 for 2D, Cubemap, and Array textures.
+---
+---@return number depth # The depth of the volume Texture.
+function Texture:getDepth() end
+
+---
+---Gets the comparison mode used when sampling from a depth texture in a shader.
+---
+---Depth texture comparison modes are advanced low-level functionality typically used with shadow mapping in 3D.
+---
+---@return love.graphics.CompareMode compare # The comparison mode used when sampling from this texture in a shader, or nil if setDepthSampleMode has not been called on this Texture.
+function Texture:getDepthSampleMode() end
+
+---
+---Gets the width and height of the Texture.
+---
+---@return number width # The width of the Texture.
+---@return number height # The height of the Texture.
+function Texture:getDimensions() end
+
+---
+---Gets the filter mode of the Texture.
+---
+---@return love.graphics.FilterMode min # Filter mode to use when minifying the texture (rendering it at a smaller size on-screen than its size in pixels).
+---@return love.graphics.FilterMode mag # Filter mode to use when magnifying the texture (rendering it at a smaller size on-screen than its size in pixels).
+---@return number anisotropy # Maximum amount of anisotropic filtering used.
+function Texture:getFilter() end
+
+---
+---Gets the pixel format of the Texture.
+---
+---@return love.graphics.PixelFormat format # The pixel format the Texture was created with.
+function Texture:getFormat() end
+
+---
+---Gets the height of the Texture.
+---
+---@return number height # The height of the Texture.
+function Texture:getHeight() end
+
+---
+---Gets the number of layers / slices in an Array Texture. Returns 1 for 2D, Cubemap, and Volume textures.
+---
+---@return number layers # The number of layers in the Array Texture.
+function Texture:getLayerCount() end
+
+---
+---Gets the number of mipmaps contained in the Texture. If the texture was not created with mipmaps, it will return 1.
+---
+---@return number mipmaps # The number of mipmaps in the Texture.
+function Texture:getMipmapCount() end
+
+---
+---Gets the mipmap filter mode for a Texture. Prior to 11.0 this method only worked on Images.
+---
+---@return love.graphics.FilterMode mode # The filter mode used in between mipmap levels. nil if mipmap filtering is not enabled.
+---@return number sharpness # Value used to determine whether the image should use more or less detailed mipmap levels than normal when drawing.
+function Texture:getMipmapFilter() end
+
+---
+---Gets the width and height in pixels of the Texture.
+---
+---Texture:getDimensions gets the dimensions of the texture in units scaled by the texture's DPI scale factor, rather than pixels. Use getDimensions for calculations related to drawing the texture (calculating an origin offset, for example), and getPixelDimensions only when dealing specifically with pixels, for example when using Canvas:newImageData.
+---
+---@return number pixelwidth # The width of the Texture, in pixels.
+---@return number pixelheight # The height of the Texture, in pixels.
+function Texture:getPixelDimensions() end
+
+---
+---Gets the height in pixels of the Texture.
+---
+---DPI scale factor, rather than pixels. Use getHeight for calculations related to drawing the texture (calculating an origin offset, for example), and getPixelHeight only when dealing specifically with pixels, for example when using Canvas:newImageData.
+---
+---@return number pixelheight # The height of the Texture, in pixels.
+function Texture:getPixelHeight() end
+
+---
+---Gets the width in pixels of the Texture.
+---
+---DPI scale factor, rather than pixels. Use getWidth for calculations related to drawing the texture (calculating an origin offset, for example), and getPixelWidth only when dealing specifically with pixels, for example when using Canvas:newImageData.
+---
+---@return number pixelwidth # The width of the Texture, in pixels.
+function Texture:getPixelWidth() end
+
+---
+---Gets the type of the Texture.
+---
+---@return love.graphics.TextureType texturetype # The type of the Texture.
+function Texture:getTextureType() end
+
+---
+---Gets the width of the Texture.
+---
+---@return number width # The width of the Texture.
+function Texture:getWidth() end
+
+---
+---Gets the wrapping properties of a Texture.
+---
+---This function returns the currently set horizontal and vertical wrapping modes for the texture.
+---
+---@return love.graphics.WrapMode horiz # Horizontal wrapping mode of the texture.
+---@return love.graphics.WrapMode vert # Vertical wrapping mode of the texture.
+---@return love.graphics.WrapMode depth # Wrapping mode for the z-axis of a Volume texture.
+function Texture:getWrap() end
+
+---
+---Gets whether the Texture can be drawn and sent to a Shader.
+---
+---Canvases created with stencil and/or depth PixelFormats are not readable by default, unless readable=true is specified in the settings table passed into love.graphics.newCanvas.
+---
+---Non-readable Canvases can still be rendered to.
+---
+---@return boolean readable # Whether the Texture is readable.
+function Texture:isReadable() end
+
+---
+---Sets the comparison mode used when sampling from a depth texture in a shader. Depth texture comparison modes are advanced low-level functionality typically used with shadow mapping in 3D.
+---
+---When using a depth texture with a comparison mode set in a shader, it must be declared as a sampler2DShadow and used in a GLSL 3 Shader. The result of accessing the texture in the shader will return a float between 0 and 1, proportional to the number of samples (up to 4 samples will be used if bilinear filtering is enabled) that passed the test set by the comparison operation.
+---
+---Depth texture comparison can only be used with readable depth-formatted Canvases.
+---
+---@param compare love.graphics.CompareMode # The comparison mode used when sampling from this texture in a shader.
+function Texture:setDepthSampleMode(compare) end
+
+---
+---Sets the filter mode of the Texture.
+---
+---@param min love.graphics.FilterMode # Filter mode to use when minifying the texture (rendering it at a smaller size on-screen than its size in pixels).
+---@param mag love.graphics.FilterMode # Filter mode to use when magnifying the texture (rendering it at a larger size on-screen than its size in pixels).
+---@param anisotropy number # Maximum amount of anisotropic filtering to use.
+function Texture:setFilter(min, mag, anisotropy) end
+
+---
+---Sets the mipmap filter mode for a Texture. Prior to 11.0 this method only worked on Images.
+---
+---Mipmapping is useful when drawing a texture at a reduced scale. It can improve performance and reduce aliasing issues.
+---
+---In created with the mipmaps flag enabled for the mipmap filter to have any effect. In versions prior to 0.10.0 it's best to call this method directly after creating the image with love.graphics.newImage, to avoid bugs in certain graphics drivers.
+---
+---Due to hardware restrictions and driver bugs, in versions prior to 0.10.0 images that weren't loaded from a CompressedData must have power-of-two dimensions (64x64, 512x256, etc.) to use mipmaps.
+---
+---@param filtermode love.graphics.FilterMode # The filter mode to use in between mipmap levels. 'nearest' will often give better performance.
+---@param sharpness number # A positive sharpness value makes the texture use a more detailed mipmap level when drawing, at the expense of performance. A negative value does the reverse.
+function Texture:setMipmapFilter(filtermode, sharpness) end
+
+---
+---Sets the wrapping properties of a Texture.
+---
+---This function sets the way a Texture is repeated when it is drawn with a Quad that is larger than the texture's extent, or when a custom Shader is used which uses texture coordinates outside of [0, 1]. A texture may be clamped or set to repeat in both horizontal and vertical directions.
+---
+---Clamped textures appear only once (with the edges of the texture stretching to fill the extent of the Quad), whereas repeated ones repeat as many times as there is room in the Quad.
+---
+---@param horiz love.graphics.WrapMode # Horizontal wrapping mode of the texture.
+---@param vert love.graphics.WrapMode # Vertical wrapping mode of the texture.
+---@param depth love.graphics.WrapMode # Wrapping mode for the z-axis of a Volume texture.
+function Texture:setWrap(horiz, vert, depth) end
+
+---@class love.graphics.Video: love.graphics.Drawable, love.graphics.Object
+local Video = {}
+
+---
+---Gets the width and height of the Video in pixels.
+---
+---@return number width # The width of the Video.
+---@return number height # The height of the Video.
+function Video:getDimensions() end
+
+---
+---Gets the scaling filters used when drawing the Video.
+---
+---@return love.graphics.FilterMode min # The filter mode used when scaling the Video down.
+---@return love.graphics.FilterMode mag # The filter mode used when scaling the Video up.
+---@return number anisotropy # Maximum amount of anisotropic filtering used.
+function Video:getFilter() end
+
+---
+---Gets the height of the Video in pixels.
+---
+---@return number height # The height of the Video.
+function Video:getHeight() end
+
+---
+---Gets the audio Source used for playing back the video's audio. May return nil if the video has no audio, or if Video:setSource is called with a nil argument.
+---
+---@return love.graphics.Source source # The audio Source used for audio playback, or nil if the video has no audio.
+function Video:getSource() end
+
+---
+---Gets the VideoStream object used for decoding and controlling the video.
+---
+---@return love.graphics.VideoStream stream # The VideoStream used for decoding and controlling the video.
+function Video:getStream() end
+
+---
+---Gets the width of the Video in pixels.
+---
+---@return number width # The width of the Video.
+function Video:getWidth() end
+
+---
+---Gets whether the Video is currently playing.
+---
+---@return boolean playing # Whether the video is playing.
+function Video:isPlaying() end
+
+---
+---Pauses the Video.
+---
+function Video:pause() end
+
+---
+---Starts playing the Video. In order for the video to appear onscreen it must be drawn with love.graphics.draw.
+---
+function Video:play() end
+
+---
+---Rewinds the Video to the beginning.
+---
+function Video:rewind() end
+
+---
+---Sets the current playback position of the Video.
+---
+---@param offset number # The time in seconds since the beginning of the Video.
+function Video:seek(offset) end
+
+---
+---Sets the scaling filters used when drawing the Video.
+---
+---@param min love.graphics.FilterMode # The filter mode used when scaling the Video down.
+---@param mag love.graphics.FilterMode # The filter mode used when scaling the Video up.
+---@param anisotropy number # Maximum amount of anisotropic filtering used.
+function Video:setFilter(min, mag, anisotropy) end
+
+---
+---Sets the audio Source used for playing back the video's audio. The audio Source also controls playback speed and synchronization.
+---
+---@param source love.graphics.Source # The audio Source used for audio playback, or nil to disable audio synchronization.
+function Video:setSource(source) end
+
+---
+---Gets the current playback position of the Video.
+---
+---@return number seconds # The time in seconds since the beginning of the Video.
+function Video:tell() end
diff --git a/meta/3rd/love2d/library/love.image.lua b/meta/3rd/love2d/library/love.image.lua
index 8101e071..be6c7411 100644
--- a/meta/3rd/love2d/library/love.image.lua
+++ b/meta/3rd/love2d/library/love.image.lua
@@ -12,7 +12,7 @@ function love.image.isCompressed(filename) end
---Create a new CompressedImageData object from a compressed image file. LÖVE supports several compressed texture formats, enumerated in the CompressedImageFormat page.
---
---@param filename string # The filename of the compressed image file.
----@return CompressedImageData compressedImageData # The new CompressedImageData object.
+---@return love.image.CompressedImageData compressedImageData # The new CompressedImageData object.
function love.image.newCompressedData(filename) end
---
@@ -20,5 +20,139 @@ function love.image.newCompressedData(filename) end
---
---@param width number # The width of the ImageData.
---@param height number # The height of the ImageData.
----@return ImageData imageData # The new blank ImageData object. Each pixel's color values, (including the alpha values!) will be set to zero.
+---@return love.image.ImageData imageData # The new blank ImageData object. Each pixel's color values, (including the alpha values!) will be set to zero.
function love.image.newImageData(width, height) end
+
+---@class love.image.CompressedImageData: love.image.Data, love.image.Object
+local CompressedImageData = {}
+
+---
+---Gets the width and height of the CompressedImageData.
+---
+---@return number width # The width of the CompressedImageData.
+---@return number height # The height of the CompressedImageData.
+function CompressedImageData:getDimensions() end
+
+---
+---Gets the format of the CompressedImageData.
+---
+---@return love.image.CompressedImageFormat format # The format of the CompressedImageData.
+function CompressedImageData:getFormat() end
+
+---
+---Gets the height of the CompressedImageData.
+---
+---@return number height # The height of the CompressedImageData.
+function CompressedImageData:getHeight() end
+
+---
+---Gets the number of mipmap levels in the CompressedImageData. The base mipmap level (original image) is included in the count.
+---
+---@return number mipmaps # The number of mipmap levels stored in the CompressedImageData.
+function CompressedImageData:getMipmapCount() end
+
+---
+---Gets the width of the CompressedImageData.
+---
+---@return number width # The width of the CompressedImageData.
+function CompressedImageData:getWidth() end
+
+---@class love.image.ImageData: love.image.Data, love.image.Object
+local ImageData = {}
+
+---
+---Encodes the ImageData and optionally writes it to the save directory.
+---
+---@param format love.image.ImageFormat # The format to encode the image as.
+---@param filename string # The filename to write the file to. If nil, no file will be written but the FileData will still be returned.
+---@return love.image.FileData filedata # The encoded image as a new FileData object.
+function ImageData:encode(format, filename) end
+
+---
+---Gets the width and height of the ImageData in pixels.
+---
+---@return number width # The width of the ImageData in pixels.
+---@return number height # The height of the ImageData in pixels.
+function ImageData:getDimensions() end
+
+---
+---Gets the height of the ImageData in pixels.
+---
+---@return number height # The height of the ImageData in pixels.
+function ImageData:getHeight() end
+
+---
+---Gets the color of a pixel at a specific position in the image.
+---
+---Valid x and y values start at 0 and go up to image width and height minus 1. Non-integer values are floored.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param x number # The position of the pixel on the x-axis.
+---@param y number # The position of the pixel on the y-axis.
+---@return number r # The red component (0-1).
+---@return number g # The green component (0-1).
+---@return number b # The blue component (0-1).
+---@return number a # The alpha component (0-1).
+function ImageData:getPixel(x, y) end
+
+---
+---Gets the width of the ImageData in pixels.
+---
+---@return number width # The width of the ImageData in pixels.
+function ImageData:getWidth() end
+
+---
+---Transform an image by applying a function to every pixel.
+---
+---This function is a higher-order function. It takes another function as a parameter, and calls it once for each pixel in the ImageData.
+---
+---The passed function is called with six parameters for each pixel in turn. The parameters are numbers that represent the x and y coordinates of the pixel and its red, green, blue and alpha values. The function should return the new red, green, blue, and alpha values for that pixel.
+---
+---function pixelFunction(x, y, r, g, b, a)
+---
+--- -- template for defining your own pixel mapping function
+---
+--- -- perform computations giving the new values for r, g, b and a
+---
+--- -- ...
+---
+--- return r, g, b, a
+---
+---end
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param pixelFunction function # Function to apply to every pixel.
+---@param x number # The x-axis of the top-left corner of the area within the ImageData to apply the function to.
+---@param y number # The y-axis of the top-left corner of the area within the ImageData to apply the function to.
+---@param width number # The width of the area within the ImageData to apply the function to.
+---@param height number # The height of the area within the ImageData to apply the function to.
+function ImageData:mapPixel(pixelFunction, x, y, width, height) end
+
+---
+---Paste into ImageData from another source ImageData.
+---
+---@param source love.image.ImageData # Source ImageData from which to copy.
+---@param dx number # Destination top-left position on x-axis.
+---@param dy number # Destination top-left position on y-axis.
+---@param sx number # Source top-left position on x-axis.
+---@param sy number # Source top-left position on y-axis.
+---@param sw number # Source width.
+---@param sh number # Source height.
+function ImageData:paste(source, dx, dy, sx, sy, sw, sh) end
+
+---
+---Sets the color of a pixel at a specific position in the image.
+---
+---Valid x and y values start at 0 and go up to image width and height minus 1.
+---
+---In versions prior to 11.0, color component values were within the range of 0 to 255 instead of 0 to 1.
+---
+---@param x number # The position of the pixel on the x-axis.
+---@param y number # The position of the pixel on the y-axis.
+---@param r number # The red component (0-1).
+---@param g number # The green component (0-1).
+---@param b number # The blue component (0-1).
+---@param a number # The alpha component (0-1).
+function ImageData:setPixel(x, y, r, g, b, a) end
diff --git a/meta/3rd/love2d/library/love.joystick.lua b/meta/3rd/love2d/library/love.joystick.lua
index ec29c3c8..193f2b94 100644
--- a/meta/3rd/love2d/library/love.joystick.lua
+++ b/meta/3rd/love2d/library/love.joystick.lua
@@ -47,9 +47,156 @@ function love.joystick.saveGamepadMappings(filename) end
---The virtual gamepad buttons and axes are designed around the Xbox 360 controller layout.
---
---@param guid string # The OS-dependent GUID for the type of Joystick the binding will affect.
----@param button GamepadButton # The virtual gamepad button to bind.
----@param inputtype JoystickInputType # The type of input to bind the virtual gamepad button to.
+---@param button love.joystick.GamepadButton # The virtual gamepad button to bind.
+---@param inputtype love.joystick.JoystickInputType # The type of input to bind the virtual gamepad button to.
---@param inputindex number # The index of the axis, button, or hat to bind the virtual gamepad button to.
----@param hatdir JoystickHat # The direction of the hat, if the virtual gamepad button will be bound to a hat. nil otherwise.
+---@param hatdir love.joystick.JoystickHat # The direction of the hat, if the virtual gamepad button will be bound to a hat. nil otherwise.
---@return boolean success # Whether the virtual gamepad button was successfully bound.
function love.joystick.setGamepadMapping(guid, button, inputtype, inputindex, hatdir) end
+
+---@class love.joystick.Joystick: love.joystick.Object
+local Joystick = {}
+
+---
+---Gets the direction of each axis.
+---
+---@return number axisDir1 # Direction of axis1.
+---@return number axisDir2 # Direction of axis2.
+---@return number axisDirN # Direction of axisN.
+function Joystick:getAxes() end
+
+---
+---Gets the direction of an axis.
+---
+---@param axis number # The index of the axis to be checked.
+---@return number direction # Current value of the axis.
+function Joystick:getAxis(axis) end
+
+---
+---Gets the number of axes on the joystick.
+---
+---@return number axes # The number of axes available.
+function Joystick:getAxisCount() end
+
+---
+---Gets the number of buttons on the joystick.
+---
+---@return number buttons # The number of buttons available.
+function Joystick:getButtonCount() end
+
+---
+---Gets the USB vendor ID, product ID, and product version numbers of joystick which consistent across operating systems.
+---
+---Can be used to show different icons, etc. for different gamepads.
+---
+---@return number vendorID # The USB vendor ID of the joystick.
+---@return number productID # The USB product ID of the joystick.
+---@return number productVersion # The product version of the joystick.
+function Joystick:getDeviceInfo() end
+
+---
+---Gets a stable GUID unique to the type of the physical joystick which does not change over time. For example, all Sony Dualshock 3 controllers in OS X have the same GUID. The value is platform-dependent.
+---
+---@return string guid # The Joystick type's OS-dependent unique identifier.
+function Joystick:getGUID() end
+
+---
+---Gets the direction of a virtual gamepad axis. If the Joystick isn't recognized as a gamepad or isn't connected, this function will always return 0.
+---
+---@param axis love.joystick.GamepadAxis # The virtual axis to be checked.
+---@return number direction # Current value of the axis.
+function Joystick:getGamepadAxis(axis) end
+
+---
+---Gets the button, axis or hat that a virtual gamepad input is bound to.
+---
+---@param axis love.joystick.GamepadAxis # The virtual gamepad axis to get the binding for.
+---@return love.joystick.JoystickInputType inputtype # The type of input the virtual gamepad axis is bound to.
+---@return number inputindex # The index of the Joystick's button, axis or hat that the virtual gamepad axis is bound to.
+---@return love.joystick.JoystickHat hatdirection # The direction of the hat, if the virtual gamepad axis is bound to a hat. nil otherwise.
+function Joystick:getGamepadMapping(axis) end
+
+---
+---Gets the full gamepad mapping string of this Joystick, or nil if it's not recognized as a gamepad.
+---
+---The mapping string contains binding information used to map the Joystick's buttons an axes to the standard gamepad layout, and can be used later with love.joystick.loadGamepadMappings.
+---
+---@return string mappingstring # A string containing the Joystick's gamepad mappings, or nil if the Joystick is not recognized as a gamepad.
+function Joystick:getGamepadMappingString() end
+
+---
+---Gets the direction of the Joystick's hat.
+---
+---@param hat number # The index of the hat to be checked.
+---@return love.joystick.JoystickHat direction # The direction the hat is pushed.
+function Joystick:getHat(hat) end
+
+---
+---Gets the number of hats on the joystick.
+---
+---@return number hats # How many hats the joystick has.
+function Joystick:getHatCount() end
+
+---
+---Gets the joystick's unique identifier. The identifier will remain the same for the life of the game, even when the Joystick is disconnected and reconnected, but it '''will''' change when the game is re-launched.
+---
+---@return number id # The Joystick's unique identifier. Remains the same as long as the game is running.
+---@return number instanceid # Unique instance identifier. Changes every time the Joystick is reconnected. nil if the Joystick is not connected.
+function Joystick:getID() end
+
+---
+---Gets the name of the joystick.
+---
+---@return string name # The name of the joystick.
+function Joystick:getName() end
+
+---
+---Gets the current vibration motor strengths on a Joystick with rumble support.
+---
+---@return number left # Current strength of the left vibration motor on the Joystick.
+---@return number right # Current strength of the right vibration motor on the Joystick.
+function Joystick:getVibration() end
+
+---
+---Gets whether the Joystick is connected.
+---
+---@return boolean connected # True if the Joystick is currently connected, false otherwise.
+function Joystick:isConnected() end
+
+---
+---Checks if a button on the Joystick is pressed.
+---
+---LÖVE 0.9.0 had a bug which required the button indices passed to Joystick:isDown to be 0-based instead of 1-based, for example button 1 would be 0 for this function. It was fixed in 0.9.1.
+---
+---@param buttonN number # The index of a button to check.
+---@return boolean anyDown # True if any supplied button is down, false if not.
+function Joystick:isDown(buttonN) end
+
+---
+---Gets whether the Joystick is recognized as a gamepad. If this is the case, the Joystick's buttons and axes can be used in a standardized manner across different operating systems and joystick models via Joystick:getGamepadAxis, Joystick:isGamepadDown, love.gamepadpressed, and related functions.
+---
+---LÖVE automatically recognizes most popular controllers with a similar layout to the Xbox 360 controller as gamepads, but you can add more with love.joystick.setGamepadMapping.
+---
+---@return boolean isgamepad # True if the Joystick is recognized as a gamepad, false otherwise.
+function Joystick:isGamepad() end
+
+---
+---Checks if a virtual gamepad button on the Joystick is pressed. If the Joystick is not recognized as a Gamepad or isn't connected, then this function will always return false.
+---
+---@param buttonN love.joystick.GamepadButton # The gamepad button to check.
+---@return boolean anyDown # True if any supplied button is down, false if not.
+function Joystick:isGamepadDown(buttonN) end
+
+---
+---Gets whether the Joystick supports vibration.
+---
+---@return boolean supported # True if rumble / force feedback vibration is supported on this Joystick, false if not.
+function Joystick:isVibrationSupported() end
+
+---
+---Sets the vibration motor speeds on a Joystick with rumble support. Most common gamepads have this functionality, although not all drivers give proper support. Use Joystick:isVibrationSupported to check.
+---
+---@param left number # Strength of the left vibration motor on the Joystick. Must be in the range of 1.
+---@param right number # Strength of the right vibration motor on the Joystick. Must be in the range of 1.
+---@return boolean success # True if the vibration was successfully applied, false if not.
+function Joystick:setVibration(left, right) end
diff --git a/meta/3rd/love2d/library/love.keyboard.lua b/meta/3rd/love2d/library/love.keyboard.lua
index a1d06596..87674b27 100644
--- a/meta/3rd/love2d/library/love.keyboard.lua
+++ b/meta/3rd/love2d/library/love.keyboard.lua
@@ -8,8 +8,8 @@ love.keyboard = {}
---
---Scancodes are useful for creating default controls that have the same physical locations on on all systems.
---
----@param scancode Scancode # The scancode to get the key from.
----@return KeyConstant key # The key corresponding to the given scancode, or 'unknown' if the scancode doesn't map to a KeyConstant on the current system.
+---@param scancode love.keyboard.Scancode # The scancode to get the key from.
+---@return love.keyboard.KeyConstant key # The key corresponding to the given scancode, or 'unknown' if the scancode doesn't map to a KeyConstant on the current system.
function love.keyboard.getKeyFromScancode(scancode) end
---
@@ -19,8 +19,8 @@ function love.keyboard.getKeyFromScancode(scancode) end
---
---Scancodes are useful for creating default controls that have the same physical locations on on all systems.
---
----@param key KeyConstant # The key to get the scancode from.
----@return Scancode scancode # The scancode corresponding to the given key, or 'unknown' if the given key has no known physical representation on the current system.
+---@param key love.keyboard.KeyConstant # The key to get the scancode from.
+---@return love.keyboard.Scancode scancode # The scancode corresponding to the given key, or 'unknown' if the given key has no known physical representation on the current system.
function love.keyboard.getScancodeFromKey(key) end
---
@@ -44,7 +44,7 @@ function love.keyboard.hasTextInput() end
---
---Checks whether a certain key is down. Not to be confused with love.keypressed or love.keyreleased.
---
----@param key KeyConstant # The key to check.
+---@param key love.keyboard.KeyConstant # The key to check.
---@return boolean down # True if the key is down, false if not.
function love.keyboard.isDown(key) end
@@ -53,8 +53,8 @@ function love.keyboard.isDown(key) end
---
---Unlike regular KeyConstants, Scancodes are keyboard layout-independent. The scancode 'w' is used if the key in the same place as the 'w' key on an American keyboard is pressed, no matter what the key is labelled or what the user's operating system settings are.
---
----@param scancode Scancode # A Scancode to check.
----@param ... Scancode # Additional Scancodes to check.
+---@param scancode love.keyboard.Scancode # A Scancode to check.
+---@param ... love.keyboard.Scancode # Additional Scancodes to check.
---@return boolean down # True if any supplied Scancode is down, false if not.
function love.keyboard.isScancodeDown(scancode, ...) end
diff --git a/meta/3rd/love2d/library/love.lua b/meta/3rd/love2d/library/love.lua
index eb1324e5..96d1dca1 100644
--- a/meta/3rd/love2d/library/love.lua
+++ b/meta/3rd/love2d/library/love.lua
@@ -25,3 +25,62 @@ function love.hasDeprecationOutput() end
---
---@param enable boolean # Whether to enable or disable deprecation output.
function love.setDeprecationOutput(enable) end
+
+---@class love.Data: love.Object
+local Data = {}
+
+---
+---Creates a new copy of the Data object.
+---
+---@return love.Data clone # The new copy.
+function Data:clone() end
+
+---
+---Gets an FFI pointer to the Data.
+---
+---This function should be preferred instead of Data:getPointer because the latter uses light userdata which can't store more all possible memory addresses on some new ARM64 architectures, when LuaJIT is used.
+---
+---@return ffi.cdata* pointer # A raw void* pointer to the Data, or nil if FFI is unavailable.
+function Data:getFFIPointer() end
+
+---
+---Gets a pointer to the Data. Can be used with libraries such as LuaJIT's FFI.
+---
+---@return lightuserdata pointer # A raw pointer to the Data.
+function Data:getPointer() end
+
+---
+---Gets the Data's size in bytes.
+---
+---@return number size # The size of the Data in bytes.
+function Data:getSize() end
+
+---
+---Gets the full Data as a string.
+---
+---@return string data # The raw data.
+function Data:getString() end
+
+---@class love.Object
+local Object = {}
+
+---
+---Destroys the object's Lua reference. The object will be completely deleted if it's not referenced by any other LÖVE object or thread.
+---
+---This method can be used to immediately clean up resources without waiting for Lua's garbage collector.
+---
+---@return boolean success # True if the object was released by this call, false if it had been previously released.
+function Object:release() end
+
+---
+---Gets the type of the object as a string.
+---
+---@return string type # The type as a string.
+function Object:type() end
+
+---
+---Checks whether an object is of a certain type. If the object has the type with the specified name in its hierarchy, this function will return true.
+---
+---@param name string # The name of the type to check for.
+---@return boolean b # True if the object is of the specified type, false otherwise.
+function Object:typeOf(name) end
diff --git a/meta/3rd/love2d/library/love.math.lua b/meta/3rd/love2d/library/love.math.lua
index d6ffac28..137d506d 100644
--- a/meta/3rd/love2d/library/love.math.lua
+++ b/meta/3rd/love2d/library/love.math.lua
@@ -31,15 +31,15 @@ function love.math.colorToBytes(r, g, b, a) end
---Compresses a string or data using a specific compression algorithm.
---
---@param rawstring string # The raw (un-compressed) string to compress.
----@param format CompressedDataFormat # The format to use when compressing the string.
+---@param format love.math.CompressedDataFormat # The format to use when compressing the string.
---@param level number # The level of compression to use, between 0 and 9. -1 indicates the default level. The meaning of this argument depends on the compression format being used.
----@return CompressedData compressedData # A new Data object containing the compressed version of the string.
+---@return love.math.CompressedData compressedData # A new Data object containing the compressed version of the string.
function love.math.compress(rawstring, format, level) end
---
---Decompresses a CompressedData or previously compressed string or Data object.
---
----@param compressedData CompressedData # The compressed data to decompress.
+---@param compressedData love.math.CompressedData # The compressed data to decompress.
---@return string rawstring # A string containing the raw decompressed data.
function love.math.decompress(compressedData) end
@@ -107,19 +107,19 @@ function love.math.linearToGamma(lr, lg, lb) end
---The number of vertices in the control polygon determines the degree of the curve, e.g. three vertices define a quadratic (degree 2) Bézier curve, four vertices define a cubic (degree 3) Bézier curve, etc.
---
---@param vertices table # The vertices of the control polygon as a table in the form of {x1, y1, x2, y2, x3, y3, ...}.
----@return BezierCurve curve # A Bézier curve object.
+---@return love.math.BezierCurve curve # A Bézier curve object.
function love.math.newBezierCurve(vertices) end
---
---Creates a new RandomGenerator object which is completely independent of other RandomGenerator objects and random functions.
---
----@return RandomGenerator rng # The new Random Number Generator object.
+---@return love.math.RandomGenerator rng # The new Random Number Generator object.
function love.math.newRandomGenerator() end
---
---Creates a new Transform object.
---
----@return Transform transform # The new Transform object.
+---@return love.math.Transform transform # The new Transform object.
function love.math.newTransform() end
---
@@ -167,3 +167,294 @@ function love.math.setRandomState(state) end
---@param polygon table # Polygon to triangulate. Must not intersect itself.
---@return table triangles # List of triangles the polygon is composed of, in the form of {{x1, y1, x2, y2, x3, y3}, {x1, y1, x2, y2, x3, y3}, ...}.
function love.math.triangulate(polygon) end
+
+---@class love.math.BezierCurve: love.math.Object
+local BezierCurve = {}
+
+---
+---Evaluate Bézier curve at parameter t. The parameter must be between 0 and 1 (inclusive).
+---
+---This function can be used to move objects along paths or tween parameters. However it should not be used to render the curve, see BezierCurve:render for that purpose.
+---
+---@param t number # Where to evaluate the curve.
+---@return number x # x coordinate of the curve at parameter t.
+---@return number y # y coordinate of the curve at parameter t.
+function BezierCurve:evaluate(t) end
+
+---
+---Get coordinates of the i-th control point. Indices start with 1.
+---
+---@param i number # Index of the control point.
+---@return number x # Position of the control point along the x axis.
+---@return number y # Position of the control point along the y axis.
+function BezierCurve:getControlPoint(i) end
+
+---
+---Get the number of control points in the Bézier curve.
+---
+---@return number count # The number of control points.
+function BezierCurve:getControlPointCount() end
+
+---
+---Get degree of the Bézier curve. The degree is equal to number-of-control-points - 1.
+---
+---@return number degree # Degree of the Bézier curve.
+function BezierCurve:getDegree() end
+
+---
+---Get the derivative of the Bézier curve.
+---
+---This function can be used to rotate sprites moving along a curve in the direction of the movement and compute the direction perpendicular to the curve at some parameter t.
+---
+---@return love.math.BezierCurve derivative # The derivative curve.
+function BezierCurve:getDerivative() end
+
+---
+---Gets a BezierCurve that corresponds to the specified segment of this BezierCurve.
+---
+---@param startpoint number # The starting point along the curve. Must be between 0 and 1.
+---@param endpoint number # The end of the segment. Must be between 0 and 1.
+---@return love.math.BezierCurve curve # A BezierCurve that corresponds to the specified segment.
+function BezierCurve:getSegment(startpoint, endpoint) end
+
+---
+---Insert control point as the new i-th control point. Existing control points from i onwards are pushed back by 1. Indices start with 1. Negative indices wrap around: -1 is the last control point, -2 the one before the last, etc.
+---
+---@param x number # Position of the control point along the x axis.
+---@param y number # Position of the control point along the y axis.
+---@param i number # Index of the control point.
+function BezierCurve:insertControlPoint(x, y, i) end
+
+---
+---Removes the specified control point.
+---
+---@param index number # The index of the control point to remove.
+function BezierCurve:removeControlPoint(index) end
+
+---
+---Get a list of coordinates to be used with love.graphics.line.
+---
+---This function samples the Bézier curve using recursive subdivision. You can control the recursion depth using the depth parameter.
+---
+---If you are just interested to know the position on the curve given a parameter, use BezierCurve:evaluate.
+---
+---@param depth number # Number of recursive subdivision steps.
+---@return table coordinates # List of x,y-coordinate pairs of points on the curve.
+function BezierCurve:render(depth) end
+
+---
+---Get a list of coordinates on a specific part of the curve, to be used with love.graphics.line.
+---
+---This function samples the Bézier curve using recursive subdivision. You can control the recursion depth using the depth parameter.
+---
+---If you are just need to know the position on the curve given a parameter, use BezierCurve:evaluate.
+---
+---@param startpoint number # The starting point along the curve. Must be between 0 and 1.
+---@param endpoint number # The end of the segment to render. Must be between 0 and 1.
+---@param depth number # Number of recursive subdivision steps.
+---@return table coordinates # List of x,y-coordinate pairs of points on the specified part of the curve.
+function BezierCurve:renderSegment(startpoint, endpoint, depth) end
+
+---
+---Rotate the Bézier curve by an angle.
+---
+---@param angle number # Rotation angle in radians.
+---@param ox number # X coordinate of the rotation center.
+---@param oy number # Y coordinate of the rotation center.
+function BezierCurve:rotate(angle, ox, oy) end
+
+---
+---Scale the Bézier curve by a factor.
+---
+---@param s number # Scale factor.
+---@param ox number # X coordinate of the scaling center.
+---@param oy number # Y coordinate of the scaling center.
+function BezierCurve:scale(s, ox, oy) end
+
+---
+---Set coordinates of the i-th control point. Indices start with 1.
+---
+---@param i number # Index of the control point.
+---@param x number # Position of the control point along the x axis.
+---@param y number # Position of the control point along the y axis.
+function BezierCurve:setControlPoint(i, x, y) end
+
+---
+---Move the Bézier curve by an offset.
+---
+---@param dx number # Offset along the x axis.
+---@param dy number # Offset along the y axis.
+function BezierCurve:translate(dx, dy) end
+
+---@class love.math.RandomGenerator: love.math.Object
+local RandomGenerator = {}
+
+---
+---Gets the seed of the random number generator object.
+---
+---The seed is split into two numbers due to Lua's use of doubles for all number values - doubles can't accurately represent integer values above 2^53, but the seed value is an integer number in the range of 2^64 - 1.
+---
+---@return number low # Integer number representing the lower 32 bits of the RandomGenerator's 64 bit seed value.
+---@return number high # Integer number representing the higher 32 bits of the RandomGenerator's 64 bit seed value.
+function RandomGenerator:getSeed() end
+
+---
+---Gets the current state of the random number generator. This returns an opaque string which is only useful for later use with RandomGenerator:setState in the same major version of LÖVE.
+---
+---This is different from RandomGenerator:getSeed in that getState gets the RandomGenerator's current state, whereas getSeed gets the previously set seed number.
+---
+---@return string state # The current state of the RandomGenerator object, represented as a string.
+function RandomGenerator:getState() end
+
+---
+---Generates a pseudo-random number in a platform independent manner.
+---
+---@return number number # The pseudo-random number.
+function RandomGenerator:random() end
+
+---
+---Get a normally distributed pseudo random number.
+---
+---@param stddev number # Standard deviation of the distribution.
+---@param mean number # The mean of the distribution.
+---@return number number # Normally distributed random number with variance (stddev)² and the specified mean.
+function RandomGenerator:randomNormal(stddev, mean) end
+
+---
+---Sets the seed of the random number generator using the specified integer number.
+---
+---@param seed number # The integer number with which you want to seed the randomization. Must be within the range of 2^53.
+function RandomGenerator:setSeed(seed) end
+
+---
+---Sets the current state of the random number generator. The value used as an argument for this function is an opaque string and should only originate from a previous call to RandomGenerator:getState in the same major version of LÖVE.
+---
+---This is different from RandomGenerator:setSeed in that setState directly sets the RandomGenerator's current implementation-dependent state, whereas setSeed gives it a new seed value.
+---
+---@param state string # The new state of the RandomGenerator object, represented as a string. This should originate from a previous call to RandomGenerator:getState.
+function RandomGenerator:setState(state) end
+
+---@class love.math.Transform: love.math.Object
+local Transform = {}
+
+---
+---Applies the given other Transform object to this one.
+---
+---This effectively multiplies this Transform's internal transformation matrix with the other Transform's (i.e. self * other), and stores the result in this object.
+---
+---@param other love.math.Transform # The other Transform object to apply to this Transform.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:apply(other) end
+
+---
+---Creates a new copy of this Transform.
+---
+---@return love.math.Transform clone # The copy of this Transform.
+function Transform:clone() end
+
+---
+---Gets the internal 4x4 transformation matrix stored by this Transform. The matrix is returned in row-major order.
+---
+---@return number e1_1 # The first column of the first row of the matrix.
+---@return number e1_2 # The second column of the first row of the matrix.
+---@return number ... # Additional matrix elements.
+---@return number e4_4 # The fourth column of the fourth row of the matrix.
+function Transform:getMatrix() end
+
+---
+---Creates a new Transform containing the inverse of this Transform.
+---
+---@return love.math.Transform inverse # A new Transform object representing the inverse of this Transform's matrix.
+function Transform:inverse() end
+
+---
+---Applies the reverse of the Transform object's transformation to the given 2D position.
+---
+---This effectively converts the given position from the local coordinate space of the Transform into global coordinates.
+---
+---One use of this method can be to convert a screen-space mouse position into global world coordinates, if the given Transform has transformations applied that are used for a camera system in-game.
+---
+---@param localX number # The x component of the position with the transform applied.
+---@param localY number # The y component of the position with the transform applied.
+---@return number globalX # The x component of the position in global coordinates.
+---@return number globalY # The y component of the position in global coordinates.
+function Transform:inverseTransformPoint(localX, localY) end
+
+---
+---Checks whether the Transform is an affine transformation.
+---
+---@return boolean affine # true if the transform object is an affine transformation, false otherwise.
+function Transform:isAffine2DTransform() end
+
+---
+---Resets the Transform to an identity state. All previously applied transformations are erased.
+---
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:reset() end
+
+---
+---Applies a rotation to the Transform's coordinate system. This method does not reset any previously applied transformations.
+---
+---@param angle number # The relative angle in radians to rotate this Transform by.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:rotate(angle) end
+
+---
+---Scales the Transform's coordinate system. This method does not reset any previously applied transformations.
+---
+---@param sx number # The relative scale factor along the x-axis.
+---@param sy number # The relative scale factor along the y-axis.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:scale(sx, sy) end
+
+---
+---Directly sets the Transform's internal 4x4 transformation matrix.
+---
+---@param e1_1 number # The first column of the first row of the matrix.
+---@param e1_2 number # The second column of the first row of the matrix.
+---@param ... number # Additional matrix elements.
+---@param e4_4 number # The fourth column of the fourth row of the matrix.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:setMatrix(e1_1, e1_2, ..., e4_4) end
+
+---
+---Resets the Transform to the specified transformation parameters.
+---
+---@param x number # The position of the Transform on the x-axis.
+---@param y number # The position of the Transform on the y-axis.
+---@param angle number # The orientation of the Transform in radians.
+---@param sx number # Scale factor on the x-axis.
+---@param sy number # Scale factor on the y-axis.
+---@param ox number # Origin offset on the x-axis.
+---@param oy number # Origin offset on the y-axis.
+---@param kx number # Shearing / skew factor on the x-axis.
+---@param ky number # Shearing / skew factor on the y-axis.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:setTransformation(x, y, angle, sx, sy, ox, oy, kx, ky) end
+
+---
+---Applies a shear factor (skew) to the Transform's coordinate system. This method does not reset any previously applied transformations.
+---
+---@param kx number # The shear factor along the x-axis.
+---@param ky number # The shear factor along the y-axis.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:shear(kx, ky) end
+
+---
+---Applies the Transform object's transformation to the given 2D position.
+---
+---This effectively converts the given position from global coordinates into the local coordinate space of the Transform.
+---
+---@param globalX number # The x component of the position in global coordinates.
+---@param globalY number # The y component of the position in global coordinates.
+---@return number localX # The x component of the position with the transform applied.
+---@return number localY # The y component of the position with the transform applied.
+function Transform:transformPoint(globalX, globalY) end
+
+---
+---Applies a translation to the Transform's coordinate system. This method does not reset any previously applied transformations.
+---
+---@param dx number # The relative translation along the x-axis.
+---@param dy number # The relative translation along the y-axis.
+---@return love.math.Transform transform # The Transform object the method was called on. Allows easily chaining Transform methods.
+function Transform:translate(dx, dy) end
diff --git a/meta/3rd/love2d/library/love.mouse.lua b/meta/3rd/love2d/library/love.mouse.lua
index 6a0dc64e..3db27a46 100644
--- a/meta/3rd/love2d/library/love.mouse.lua
+++ b/meta/3rd/love2d/library/love.mouse.lua
@@ -4,7 +4,7 @@ love.mouse = {}
---
---Gets the current Cursor.
---
----@return Cursor cursor # The current cursor, or nil if no cursor is set.
+---@return love.mouse.Cursor cursor # The current cursor, or nil if no cursor is set.
function love.mouse.getCursor() end
---
@@ -29,8 +29,8 @@ function love.mouse.getRelativeMode() end
---
---Hardware cursors are framerate-independent and work the same way as normal operating system cursors. Unlike drawing an image at the mouse's current coordinates, hardware cursors never have visible lag between when the mouse is moved and when the cursor position updates, even at low framerates.
---
----@param ctype CursorType # The type of system cursor to get.
----@return Cursor cursor # The Cursor object representing the system cursor type.
+---@param ctype love.mouse.CursorType # The type of system cursor to get.
+---@return love.mouse.Cursor cursor # The Cursor object representing the system cursor type.
function love.mouse.getSystemCursor(ctype) end
---
@@ -82,16 +82,16 @@ function love.mouse.isVisible() end
---
---The hot spot is the point the operating system uses to determine what was clicked and at what position the mouse cursor is. For example, the normal arrow pointer normally has its hot spot at the top left of the image, but a crosshair cursor might have it in the middle.
---
----@param imageData ImageData # The ImageData to use for the new Cursor.
+---@param imageData love.mouse.ImageData # The ImageData to use for the new Cursor.
---@param hotx number # The x-coordinate in the ImageData of the cursor's hot spot.
---@param hoty number # The y-coordinate in the ImageData of the cursor's hot spot.
----@return Cursor cursor # The new Cursor object.
+---@return love.mouse.Cursor cursor # The new Cursor object.
function love.mouse.newCursor(imageData, hotx, hoty) end
---
---Sets the current mouse cursor.
---
----@param cursor Cursor # The Cursor object to use as the current mouse cursor.
+---@param cursor love.mouse.Cursor # The Cursor object to use as the current mouse cursor.
function love.mouse.setCursor(cursor) end
---
@@ -138,3 +138,12 @@ function love.mouse.setX(x) end
---
---@param y number # The new position of the mouse along the y-axis.
function love.mouse.setY(y) end
+
+---@class love.mouse.Cursor: love.mouse.Object
+local Cursor = {}
+
+---
+---Gets the type of the Cursor.
+---
+---@return love.mouse.CursorType ctype # The type of the Cursor.
+function Cursor:getType() end
diff --git a/meta/3rd/love2d/library/love.physics.lua b/meta/3rd/love2d/library/love.physics.lua
index 91428e61..4d6d99ea 100644
--- a/meta/3rd/love2d/library/love.physics.lua
+++ b/meta/3rd/love2d/library/love.physics.lua
@@ -4,8 +4,8 @@ love.physics = {}
---
---Returns the two closest points between two fixtures and their distance.
---
----@param fixture1 Fixture # The first fixture.
----@param fixture2 Fixture # The second fixture.
+---@param fixture1 love.physics.Fixture # The first fixture.
+---@param fixture2 love.physics.Fixture # The second fixture.
---@return number distance # The distance of the two points.
---@return number x1 # The x-coordinate of the first point.
---@return number y1 # The y-coordinate of the first point.
@@ -36,11 +36,11 @@ function love.physics.getMeter() end
---
---The mass of the body gets calculated when a Fixture is attached or removed, but can be changed at any time with Body:setMass or Body:resetMassData.
---
----@param world World # The world to create the body in.
+---@param world love.physics.World # The world to create the body in.
---@param x number # The x position of the body.
---@param y number # The y position of the body.
----@param type BodyType # The type of the body.
----@return Body body # A new body.
+---@param type love.physics.BodyType # The type of the body.
+---@return love.physics.Body body # A new body.
function love.physics.newBody(world, x, y, type) end
---
@@ -52,14 +52,14 @@ function love.physics.newBody(world, x, y, type) end
---@param x2 number # The x position of the second point.
---@param y2 number # The y position of the second point.
---@param ... number # Additional point positions.
----@return ChainShape shape # The new shape.
+---@return love.physics.ChainShape shape # The new shape.
function love.physics.newChainShape(loop, x1, y1, x2, y2, ...) end
---
---Creates a new CircleShape.
---
---@param radius number # The radius of the circle.
----@return CircleShape shape # The new shape.
+---@return love.physics.CircleShape shape # The new shape.
function love.physics.newCircleShape(radius) end
---
@@ -67,14 +67,14 @@ function love.physics.newCircleShape(radius) end
---
---This joint constrains the distance between two points on two bodies to be constant. These two points are specified in world coordinates and the two bodies are assumed to be in place when this joint is created. The first anchor point is connected to the first body and the second to the second body, and the points define the length of the distance joint.
---
----@param body1 Body # The first body to attach to the joint.
----@param body2 Body # The second body to attach to the joint.
+---@param body1 love.physics.Body # The first body to attach to the joint.
+---@param body2 love.physics.Body # The second body to attach to the joint.
---@param x1 number # The x position of the first anchor point (world space).
---@param y1 number # The y position of the first anchor point (world space).
---@param x2 number # The x position of the second anchor point (world space).
---@param y2 number # The y position of the second anchor point (world space).
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return DistanceJoint joint # The new distance joint.
+---@return love.physics.DistanceJoint joint # The new distance joint.
function love.physics.newDistanceJoint(body1, body2, x1, y1, x2, y2, collideConnected) end
---
@@ -84,7 +84,7 @@ function love.physics.newDistanceJoint(body1, body2, x1, y1, x2, y2, collideConn
---@param y1 number # The y position of the first point.
---@param x2 number # The x position of the second point.
---@param y2 number # The y position of the second point.
----@return EdgeShape shape # The new shape.
+---@return love.physics.EdgeShape shape # The new shape.
function love.physics.newEdgeShape(x1, y1, x2, y2) end
---
@@ -92,21 +92,21 @@ function love.physics.newEdgeShape(x1, y1, x2, y2) end
---
---Note that the Shape object is copied rather than kept as a reference when the Fixture is created. To get the Shape object that the Fixture owns, use Fixture:getShape.
---
----@param body Body # The body which gets the fixture attached.
----@param shape Shape # The shape to be copied to the fixture.
+---@param body love.physics.Body # The body which gets the fixture attached.
+---@param shape love.physics.Shape # The shape to be copied to the fixture.
---@param density number # The density of the fixture.
----@return Fixture fixture # The new fixture.
+---@return love.physics.Fixture fixture # The new fixture.
function love.physics.newFixture(body, shape, density) end
---
---Create a friction joint between two bodies. A FrictionJoint applies friction to a body.
---
----@param body1 Body # The first body to attach to the joint.
----@param body2 Body # The second body to attach to the joint.
+---@param body1 love.physics.Body # The first body to attach to the joint.
+---@param body2 love.physics.Body # The second body to attach to the joint.
---@param x number # The x position of the anchor point.
---@param y number # The y position of the anchor point.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return FrictionJoint joint # The new FrictionJoint.
+---@return love.physics.FrictionJoint joint # The new FrictionJoint.
function love.physics.newFrictionJoint(body1, body2, x, y, collideConnected) end
---
@@ -116,11 +116,11 @@ function love.physics.newFrictionJoint(body1, body2, x, y, collideConnected) end
---
---The gear joint has a ratio the determines how the angular or distance values of the connected joints relate to each other. The formula coordinate1 + ratio * coordinate2 always has a constant value that is set when the gear joint is created.
---
----@param joint1 Joint # The first joint to connect with a gear joint.
----@param joint2 Joint # The second joint to connect with a gear joint.
+---@param joint1 love.physics.Joint # The first joint to connect with a gear joint.
+---@param joint2 love.physics.Joint # The second joint to connect with a gear joint.
---@param ratio number # The gear ratio.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return GearJoint joint # The new gear joint.
+---@return love.physics.GearJoint joint # The new gear joint.
function love.physics.newGearJoint(joint1, joint2, ratio, collideConnected) end
---
@@ -128,10 +128,10 @@ function love.physics.newGearJoint(joint1, joint2, ratio, collideConnected) end
---
---Position and rotation offsets can be specified once the MotorJoint has been created, as well as the maximum motor force and torque that will be be applied to reach the target offsets.
---
----@param body1 Body # The first body to attach to the joint.
----@param body2 Body # The second body to attach to the joint.
+---@param body1 love.physics.Body # The first body to attach to the joint.
+---@param body2 love.physics.Body # The second body to attach to the joint.
---@param correctionFactor number # The joint's initial position correction factor, in the range of 1.
----@return MotorJoint joint # The new MotorJoint.
+---@return love.physics.MotorJoint joint # The new MotorJoint.
function love.physics.newMotorJoint(body1, body2, correctionFactor) end
---
@@ -141,10 +141,10 @@ function love.physics.newMotorJoint(body1, body2, correctionFactor) end
---
---The advantage of using a MouseJoint instead of just changing a body position directly is that collisions and reactions to other joints are handled by the physics engine.
---
----@param body Body # The body to attach to the mouse.
+---@param body love.physics.Body # The body to attach to the mouse.
---@param x number # The x position of the connecting point.
---@param y number # The y position of the connecting point.
----@return MouseJoint joint # The new mouse joint.
+---@return love.physics.MouseJoint joint # The new mouse joint.
function love.physics.newMouseJoint(body, x, y) end
---
@@ -159,7 +159,7 @@ function love.physics.newMouseJoint(body, x, y) end
---@param x3 number # The x position of the third point.
---@param y3 number # The y position of the third point.
---@param ... number # You can continue passing more point positions to create the PolygonShape.
----@return PolygonShape shape # A new PolygonShape.
+---@return love.physics.PolygonShape shape # A new PolygonShape.
function love.physics.newPolygonShape(x1, y1, x2, y2, x3, y3, ...) end
---
@@ -167,14 +167,14 @@ function love.physics.newPolygonShape(x1, y1, x2, y2, x3, y3, ...) end
---
---A prismatic joint constrains two bodies to move relatively to each other on a specified axis. It does not allow for relative rotation. Its definition and operation are similar to a revolute joint, but with translation and force substituted for angle and torque.
---
----@param body1 Body # The first body to connect with a prismatic joint.
----@param body2 Body # The second body to connect with a prismatic joint.
+---@param body1 love.physics.Body # The first body to connect with a prismatic joint.
+---@param body2 love.physics.Body # The second body to connect with a prismatic joint.
---@param x number # The x coordinate of the anchor point.
---@param y number # The y coordinate of the anchor point.
---@param ax number # The x coordinate of the axis vector.
---@param ay number # The y coordinate of the axis vector.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return PrismaticJoint joint # The new prismatic joint.
+---@return love.physics.PrismaticJoint joint # The new prismatic joint.
function love.physics.newPrismaticJoint(body1, body2, x, y, ax, ay, collideConnected) end
---
@@ -184,8 +184,8 @@ function love.physics.newPrismaticJoint(body1, body2, x, y, ax, ay, collideConne
---
---Pulley joints can behave unpredictably if one side is fully extended. It is recommended that the method setMaxLengths  be used to constrain the maximum lengths each side can attain.
---
----@param body1 Body # The first body to connect with a pulley joint.
----@param body2 Body # The second body to connect with a pulley joint.
+---@param body1 love.physics.Body # The first body to connect with a pulley joint.
+---@param body2 love.physics.Body # The second body to connect with a pulley joint.
---@param gx1 number # The x coordinate of the first body's ground anchor.
---@param gy1 number # The y coordinate of the first body's ground anchor.
---@param gx2 number # The x coordinate of the second body's ground anchor.
@@ -196,7 +196,7 @@ function love.physics.newPrismaticJoint(body1, body2, x, y, ax, ay, collideConne
---@param y2 number # The y coordinate of the pulley joint anchor in the second body.
---@param ratio number # The joint ratio.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return PulleyJoint joint # The new pulley joint.
+---@return love.physics.PulleyJoint joint # The new pulley joint.
function love.physics.newPulleyJoint(body1, body2, gx1, gy1, gx2, gy2, x1, y1, x2, y2, ratio, collideConnected) end
---
@@ -206,7 +206,7 @@ function love.physics.newPulleyJoint(body1, body2, gx1, gy1, gx2, gy2, x1, y1, x
---
---@param width number # The width of the rectangle.
---@param height number # The height of the rectangle.
----@return PolygonShape shape # A new PolygonShape.
+---@return love.physics.PolygonShape shape # A new PolygonShape.
function love.physics.newRectangleShape(width, height) end
---
@@ -214,50 +214,50 @@ function love.physics.newRectangleShape(width, height) end
---
---This joint connects two bodies to a point around which they can pivot.
---
----@param body1 Body # The first body.
----@param body2 Body # The second body.
+---@param body1 love.physics.Body # The first body.
+---@param body2 love.physics.Body # The second body.
---@param x number # The x position of the connecting point.
---@param y number # The y position of the connecting point.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return RevoluteJoint joint # The new revolute joint.
+---@return love.physics.RevoluteJoint joint # The new revolute joint.
function love.physics.newRevoluteJoint(body1, body2, x, y, collideConnected) end
---
---Creates a joint between two bodies. Its only function is enforcing a max distance between these bodies.
---
----@param body1 Body # The first body to attach to the joint.
----@param body2 Body # The second body to attach to the joint.
+---@param body1 love.physics.Body # The first body to attach to the joint.
+---@param body2 love.physics.Body # The second body to attach to the joint.
---@param x1 number # The x position of the first anchor point.
---@param y1 number # The y position of the first anchor point.
---@param x2 number # The x position of the second anchor point.
---@param y2 number # The y position of the second anchor point.
---@param maxLength number # The maximum distance for the bodies.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return RopeJoint joint # The new RopeJoint.
+---@return love.physics.RopeJoint joint # The new RopeJoint.
function love.physics.newRopeJoint(body1, body2, x1, y1, x2, y2, maxLength, collideConnected) end
---
---Creates a constraint joint between two bodies. A WeldJoint essentially glues two bodies together. The constraint is a bit soft, however, due to Box2D's iterative solver.
---
----@param body1 Body # The first body to attach to the joint.
----@param body2 Body # The second body to attach to the joint.
+---@param body1 love.physics.Body # The first body to attach to the joint.
+---@param body2 love.physics.Body # The second body to attach to the joint.
---@param x number # The x position of the anchor point (world space).
---@param y number # The y position of the anchor point (world space).
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return WeldJoint joint # The new WeldJoint.
+---@return love.physics.WeldJoint joint # The new WeldJoint.
function love.physics.newWeldJoint(body1, body2, x, y, collideConnected) end
---
---Creates a wheel joint.
---
----@param body1 Body # The first body.
----@param body2 Body # The second body.
+---@param body1 love.physics.Body # The first body.
+---@param body2 love.physics.Body # The second body.
---@param x number # The x position of the anchor point.
---@param y number # The y position of the anchor point.
---@param ax number # The x position of the axis unit vector.
---@param ay number # The y position of the axis unit vector.
---@param collideConnected boolean # Specifies whether the two bodies should collide with each other.
----@return WheelJoint joint # The new WheelJoint.
+---@return love.physics.WheelJoint joint # The new WheelJoint.
function love.physics.newWheelJoint(body1, body2, x, y, ax, ay, collideConnected) end
---
@@ -266,7 +266,7 @@ function love.physics.newWheelJoint(body1, body2, x, y, ax, ay, collideConnected
---@param xg number # The x component of gravity.
---@param yg number # The y component of gravity.
---@param sleep boolean # Whether the bodies in this world are allowed to sleep.
----@return World world # A brave new World.
+---@return love.physics.World world # A brave new World.
function love.physics.newWorld(xg, yg, sleep) end
---
@@ -278,3 +278,1908 @@ function love.physics.newWorld(xg, yg, sleep) end
---
---@param scale number # The scale factor as an integer.
function love.physics.setMeter(scale) end
+
+---@class love.physics.Body: love.physics.Object
+local Body = {}
+
+---
+---Applies an angular impulse to a body. This makes a single, instantaneous addition to the body momentum.
+---
+---A body with with a larger mass will react less. The reaction does '''not''' depend on the timestep, and is equivalent to applying a force continuously for 1 second. Impulses are best used to give a single push to a body. For a continuous push to a body it is better to use Body:applyForce.
+---
+---@param impulse number # The impulse in kilogram-square meter per second.
+function Body:applyAngularImpulse(impulse) end
+
+---
+---Apply force to a Body.
+---
+---A force pushes a body in a direction. A body with with a larger mass will react less. The reaction also depends on how long a force is applied: since the force acts continuously over the entire timestep, a short timestep will only push the body for a short time. Thus forces are best used for many timesteps to give a continuous push to a body (like gravity). For a single push that is independent of timestep, it is better to use Body:applyLinearImpulse.
+---
+---If the position to apply the force is not given, it will act on the center of mass of the body. The part of the force not directed towards the center of mass will cause the body to spin (and depends on the rotational inertia).
+---
+---Note that the force components and position must be given in world coordinates.
+---
+---@param fx number # The x component of force to apply to the center of mass.
+---@param fy number # The y component of force to apply to the center of mass.
+function Body:applyForce(fx, fy) end
+
+---
+---Applies an impulse to a body.
+---
+---This makes a single, instantaneous addition to the body momentum.
+---
+---An impulse pushes a body in a direction. A body with with a larger mass will react less. The reaction does '''not''' depend on the timestep, and is equivalent to applying a force continuously for 1 second. Impulses are best used to give a single push to a body. For a continuous push to a body it is better to use Body:applyForce.
+---
+---If the position to apply the impulse is not given, it will act on the center of mass of the body. The part of the impulse not directed towards the center of mass will cause the body to spin (and depends on the rotational inertia).
+---
+---Note that the impulse components and position must be given in world coordinates.
+---
+---@param ix number # The x component of the impulse applied to the center of mass.
+---@param iy number # The y component of the impulse applied to the center of mass.
+function Body:applyLinearImpulse(ix, iy) end
+
+---
+---Apply torque to a body.
+---
+---Torque is like a force that will change the angular velocity (spin) of a body. The effect will depend on the rotational inertia a body has.
+---
+---@param torque number # The torque to apply.
+function Body:applyTorque(torque) end
+
+---
+---Explicitly destroys the Body and all fixtures and joints attached to it.
+---
+---An error will occur if you attempt to use the object after calling this function. In 0.7.2, when you don't have time to wait for garbage collection, this function may be used to free the object immediately.
+---
+function Body:destroy() end
+
+---
+---Get the angle of the body.
+---
+---The angle is measured in radians. If you need to transform it to degrees, use math.deg.
+---
+---A value of 0 radians will mean 'looking to the right'. Although radians increase counter-clockwise, the y axis points down so it becomes ''clockwise'' from our point of view.
+---
+---@return number angle # The angle in radians.
+function Body:getAngle() end
+
+---
+---Gets the Angular damping of the Body
+---
+---The angular damping is the ''rate of decrease of the angular velocity over time'': A spinning body with no damping and no external forces will continue spinning indefinitely. A spinning body with damping will gradually stop spinning.
+---
+---Damping is not the same as friction - they can be modelled together. However, only damping is provided by Box2D (and LOVE).
+---
+---Damping parameters should be between 0 and infinity, with 0 meaning no damping, and infinity meaning full damping. Normally you will use a damping value between 0 and 0.1.
+---
+---@return number damping # The value of the angular damping.
+function Body:getAngularDamping() end
+
+---
+---Get the angular velocity of the Body.
+---
+---The angular velocity is the ''rate of change of angle over time''.
+---
+---It is changed in World:update by applying torques, off centre forces/impulses, and angular damping. It can be set directly with Body:setAngularVelocity.
+---
+---If you need the ''rate of change of position over time'', use Body:getLinearVelocity.
+---
+---@return number w # The angular velocity in radians/second.
+function Body:getAngularVelocity() end
+
+---
+---Gets a list of all Contacts attached to the Body.
+---
+---@return table contacts # A list with all contacts associated with the Body.
+function Body:getContacts() end
+
+---
+---Returns a table with all fixtures.
+---
+---@return table fixtures # A sequence with all fixtures.
+function Body:getFixtures() end
+
+---
+---Returns the gravity scale factor.
+---
+---@return number scale # The gravity scale factor.
+function Body:getGravityScale() end
+
+---
+---Gets the rotational inertia of the body.
+---
+---The rotational inertia is how hard is it to make the body spin.
+---
+---@return number inertia # The rotational inertial of the body.
+function Body:getInertia() end
+
+---
+---Returns a table containing the Joints attached to this Body.
+---
+---@return table joints # A sequence with the Joints attached to the Body.
+function Body:getJoints() end
+
+---
+---Gets the linear damping of the Body.
+---
+---The linear damping is the ''rate of decrease of the linear velocity over time''. A moving body with no damping and no external forces will continue moving indefinitely, as is the case in space. A moving body with damping will gradually stop moving.
+---
+---Damping is not the same as friction - they can be modelled together.
+---
+---@return number damping # The value of the linear damping.
+function Body:getLinearDamping() end
+
+---
+---Gets the linear velocity of the Body from its center of mass.
+---
+---The linear velocity is the ''rate of change of position over time''.
+---
+---If you need the ''rate of change of angle over time'', use Body:getAngularVelocity.
+---
+---If you need to get the linear velocity of a point different from the center of mass:
+---
+---* Body:getLinearVelocityFromLocalPoint allows you to specify the point in local coordinates.
+---
+---* Body:getLinearVelocityFromWorldPoint allows you to specify the point in world coordinates.
+---
+---See page 136 of 'Essential Mathematics for Games and Interactive Applications' for definitions of local and world coordinates.
+---
+---@return number x # The x-component of the velocity vector
+---@return number y # The y-component of the velocity vector
+function Body:getLinearVelocity() end
+
+---
+---Get the linear velocity of a point on the body.
+---
+---The linear velocity for a point on the body is the velocity of the body center of mass plus the velocity at that point from the body spinning.
+---
+---The point on the body must given in local coordinates. Use Body:getLinearVelocityFromWorldPoint to specify this with world coordinates.
+---
+---@param x number # The x position to measure velocity.
+---@param y number # The y position to measure velocity.
+---@return number vx # The x component of velocity at point (x,y).
+---@return number vy # The y component of velocity at point (x,y).
+function Body:getLinearVelocityFromLocalPoint(x, y) end
+
+---
+---Get the linear velocity of a point on the body.
+---
+---The linear velocity for a point on the body is the velocity of the body center of mass plus the velocity at that point from the body spinning.
+---
+---The point on the body must given in world coordinates. Use Body:getLinearVelocityFromLocalPoint to specify this with local coordinates.
+---
+---@param x number # The x position to measure velocity.
+---@param y number # The y position to measure velocity.
+---@return number vx # The x component of velocity at point (x,y).
+---@return number vy # The y component of velocity at point (x,y).
+function Body:getLinearVelocityFromWorldPoint(x, y) end
+
+---
+---Get the center of mass position in local coordinates.
+---
+---Use Body:getWorldCenter to get the center of mass in world coordinates.
+---
+---@return number x # The x coordinate of the center of mass.
+---@return number y # The y coordinate of the center of mass.
+function Body:getLocalCenter() end
+
+---
+---Transform a point from world coordinates to local coordinates.
+---
+---@param worldX number # The x position in world coordinates.
+---@param worldY number # The y position in world coordinates.
+---@return number localX # The x position in local coordinates.
+---@return number localY # The y position in local coordinates.
+function Body:getLocalPoint(worldX, worldY) end
+
+---
+---Transform a vector from world coordinates to local coordinates.
+---
+---@param worldX number # The vector x component in world coordinates.
+---@param worldY number # The vector y component in world coordinates.
+---@return number localX # The vector x component in local coordinates.
+---@return number localY # The vector y component in local coordinates.
+function Body:getLocalVector(worldX, worldY) end
+
+---
+---Get the mass of the body.
+---
+---Static bodies always have a mass of 0.
+---
+---@return number mass # The mass of the body (in kilograms).
+function Body:getMass() end
+
+---
+---Returns the mass, its center, and the rotational inertia.
+---
+---@return number x # The x position of the center of mass.
+---@return number y # The y position of the center of mass.
+---@return number mass # The mass of the body.
+---@return number inertia # The rotational inertia.
+function Body:getMassData() end
+
+---
+---Get the position of the body.
+---
+---Note that this may not be the center of mass of the body.
+---
+---@return number x # The x position.
+---@return number y # The y position.
+function Body:getPosition() end
+
+---
+---Get the position and angle of the body.
+---
+---Note that the position may not be the center of mass of the body. An angle of 0 radians will mean 'looking to the right'. Although radians increase counter-clockwise, the y axis points down so it becomes clockwise from our point of view.
+---
+---@return number x # The x component of the position.
+---@return number y # The y component of the position.
+---@return number angle # The angle in radians.
+function Body:getTransform() end
+
+---
+---Returns the type of the body.
+---
+---@return love.physics.BodyType type # The body type.
+function Body:getType() end
+
+---
+---Returns the Lua value associated with this Body.
+---
+---@return love.physics.any value # The Lua value associated with the Body.
+function Body:getUserData() end
+
+---
+---Gets the World the body lives in.
+---
+---@return love.physics.World world # The world the body lives in.
+function Body:getWorld() end
+
+---
+---Get the center of mass position in world coordinates.
+---
+---Use Body:getLocalCenter to get the center of mass in local coordinates.
+---
+---@return number x # The x coordinate of the center of mass.
+---@return number y # The y coordinate of the center of mass.
+function Body:getWorldCenter() end
+
+---
+---Transform a point from local coordinates to world coordinates.
+---
+---@param localX number # The x position in local coordinates.
+---@param localY number # The y position in local coordinates.
+---@return number worldX # The x position in world coordinates.
+---@return number worldY # The y position in world coordinates.
+function Body:getWorldPoint(localX, localY) end
+
+---
+---Transforms multiple points from local coordinates to world coordinates.
+---
+---@param x1 number # The x position of the first point.
+---@param y1 number # The y position of the first point.
+---@param x2 number # The x position of the second point.
+---@param y2 number # The y position of the second point.
+---@return number x1 # The transformed x position of the first point.
+---@return number y1 # The transformed y position of the first point.
+---@return number x2 # The transformed x position of the second point.
+---@return number y2 # The transformed y position of the second point.
+function Body:getWorldPoints(x1, y1, x2, y2) end
+
+---
+---Transform a vector from local coordinates to world coordinates.
+---
+---@param localX number # The vector x component in local coordinates.
+---@param localY number # The vector y component in local coordinates.
+---@return number worldX # The vector x component in world coordinates.
+---@return number worldY # The vector y component in world coordinates.
+function Body:getWorldVector(localX, localY) end
+
+---
+---Get the x position of the body in world coordinates.
+---
+---@return number x # The x position in world coordinates.
+function Body:getX() end
+
+---
+---Get the y position of the body in world coordinates.
+---
+---@return number y # The y position in world coordinates.
+function Body:getY() end
+
+---
+---Returns whether the body is actively used in the simulation.
+---
+---@return boolean status # True if the body is active or false if not.
+function Body:isActive() end
+
+---
+---Returns the sleep status of the body.
+---
+---@return boolean status # True if the body is awake or false if not.
+function Body:isAwake() end
+
+---
+---Get the bullet status of a body.
+---
+---There are two methods to check for body collisions:
+---
+---* at their location when the world is updated (default)
+---
+---* using continuous collision detection (CCD)
+---
+---The default method is efficient, but a body moving very quickly may sometimes jump over another body without producing a collision. A body that is set as a bullet will use CCD. This is less efficient, but is guaranteed not to jump when moving quickly.
+---
+---Note that static bodies (with zero mass) always use CCD, so your walls will not let a fast moving body pass through even if it is not a bullet.
+---
+---@return boolean status # The bullet status of the body.
+function Body:isBullet() end
+
+---
+---Gets whether the Body is destroyed. Destroyed bodies cannot be used.
+---
+---@return boolean destroyed # Whether the Body is destroyed.
+function Body:isDestroyed() end
+
+---
+---Returns whether the body rotation is locked.
+---
+---@return boolean fixed # True if the body's rotation is locked or false if not.
+function Body:isFixedRotation() end
+
+---
+---Returns the sleeping behaviour of the body.
+---
+---@return boolean allowed # True if the body is allowed to sleep or false if not.
+function Body:isSleepingAllowed() end
+
+---
+---Gets whether the Body is touching the given other Body.
+---
+---@param otherbody love.physics.Body # The other body to check.
+---@return boolean touching # True if this body is touching the other body, false otherwise.
+function Body:isTouching(otherbody) end
+
+---
+---Resets the mass of the body by recalculating it from the mass properties of the fixtures.
+---
+function Body:resetMassData() end
+
+---
+---Sets whether the body is active in the world.
+---
+---An inactive body does not take part in the simulation. It will not move or cause any collisions.
+---
+---@param active boolean # If the body is active or not.
+function Body:setActive(active) end
+
+---
+---Set the angle of the body.
+---
+---The angle is measured in radians. If you need to transform it from degrees, use math.rad.
+---
+---A value of 0 radians will mean 'looking to the right'. Although radians increase counter-clockwise, the y axis points down so it becomes ''clockwise'' from our point of view.
+---
+---It is possible to cause a collision with another body by changing its angle.
+---
+---@param angle number # The angle in radians.
+function Body:setAngle(angle) end
+
+---
+---Sets the angular damping of a Body
+---
+---See Body:getAngularDamping for a definition of angular damping.
+---
+---Angular damping can take any value from 0 to infinity. It is recommended to stay between 0 and 0.1, though. Other values will look unrealistic.
+---
+---@param damping number # The new angular damping.
+function Body:setAngularDamping(damping) end
+
+---
+---Sets the angular velocity of a Body.
+---
+---The angular velocity is the ''rate of change of angle over time''.
+---
+---This function will not accumulate anything; any impulses previously applied since the last call to World:update will be lost.
+---
+---@param w number # The new angular velocity, in radians per second
+function Body:setAngularVelocity(w) end
+
+---
+---Wakes the body up or puts it to sleep.
+---
+---@param awake boolean # The body sleep status.
+function Body:setAwake(awake) end
+
+---
+---Set the bullet status of a body.
+---
+---There are two methods to check for body collisions:
+---
+---* at their location when the world is updated (default)
+---
+---* using continuous collision detection (CCD)
+---
+---The default method is efficient, but a body moving very quickly may sometimes jump over another body without producing a collision. A body that is set as a bullet will use CCD. This is less efficient, but is guaranteed not to jump when moving quickly.
+---
+---Note that static bodies (with zero mass) always use CCD, so your walls will not let a fast moving body pass through even if it is not a bullet.
+---
+---@param status boolean # The bullet status of the body.
+function Body:setBullet(status) end
+
+---
+---Set whether a body has fixed rotation.
+---
+---Bodies with fixed rotation don't vary the speed at which they rotate. Calling this function causes the mass to be reset.
+---
+---@param isFixed boolean # Whether the body should have fixed rotation.
+function Body:setFixedRotation(isFixed) end
+
+---
+---Sets a new gravity scale factor for the body.
+---
+---@param scale number # The new gravity scale factor.
+function Body:setGravityScale(scale) end
+
+---
+---Set the inertia of a body.
+---
+---@param inertia number # The new moment of inertia, in kilograms * pixel squared.
+function Body:setInertia(inertia) end
+
+---
+---Sets the linear damping of a Body
+---
+---See Body:getLinearDamping for a definition of linear damping.
+---
+---Linear damping can take any value from 0 to infinity. It is recommended to stay between 0 and 0.1, though. Other values will make the objects look 'floaty'(if gravity is enabled).
+---
+---@param ld number # The new linear damping
+function Body:setLinearDamping(ld) end
+
+---
+---Sets a new linear velocity for the Body.
+---
+---This function will not accumulate anything; any impulses previously applied since the last call to World:update will be lost.
+---
+---@param x number # The x-component of the velocity vector.
+---@param y number # The y-component of the velocity vector.
+function Body:setLinearVelocity(x, y) end
+
+---
+---Sets a new body mass.
+---
+---@param mass number # The mass, in kilograms.
+function Body:setMass(mass) end
+
+---
+---Overrides the calculated mass data.
+---
+---@param x number # The x position of the center of mass.
+---@param y number # The y position of the center of mass.
+---@param mass number # The mass of the body.
+---@param inertia number # The rotational inertia.
+function Body:setMassData(x, y, mass, inertia) end
+
+---
+---Set the position of the body.
+---
+---Note that this may not be the center of mass of the body.
+---
+---This function cannot wake up the body.
+---
+---@param x number # The x position.
+---@param y number # The y position.
+function Body:setPosition(x, y) end
+
+---
+---Sets the sleeping behaviour of the body. Should sleeping be allowed, a body at rest will automatically sleep. A sleeping body is not simulated unless it collided with an awake body. Be wary that one can end up with a situation like a floating sleeping body if the floor was removed.
+---
+---@param allowed boolean # True if the body is allowed to sleep or false if not.
+function Body:setSleepingAllowed(allowed) end
+
+---
+---Set the position and angle of the body.
+---
+---Note that the position may not be the center of mass of the body. An angle of 0 radians will mean 'looking to the right'. Although radians increase counter-clockwise, the y axis points down so it becomes clockwise from our point of view.
+---
+---This function cannot wake up the body.
+---
+---@param x number # The x component of the position.
+---@param y number # The y component of the position.
+---@param angle number # The angle in radians.
+function Body:setTransform(x, y, angle) end
+
+---
+---Sets a new body type.
+---
+---@param type love.physics.BodyType # The new type.
+function Body:setType(type) end
+
+---
+---Associates a Lua value with the Body.
+---
+---To delete the reference, explicitly pass nil.
+---
+---@param value love.physics.any # The Lua value to associate with the Body.
+function Body:setUserData(value) end
+
+---
+---Set the x position of the body.
+---
+---This function cannot wake up the body.
+---
+---@param x number # The x position.
+function Body:setX(x) end
+
+---
+---Set the y position of the body.
+---
+---This function cannot wake up the body.
+---
+---@param y number # The y position.
+function Body:setY(y) end
+
+---@class love.physics.ChainShape: love.physics.Shape, love.physics.Object
+local ChainShape = {}
+
+---
+---Returns a child of the shape as an EdgeShape.
+---
+---@param index number # The index of the child.
+---@return love.physics.EdgeShape shape # The child as an EdgeShape.
+function ChainShape:getChildEdge(index) end
+
+---
+---Gets the vertex that establishes a connection to the next shape.
+---
+---Setting next and previous ChainShape vertices can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@return number x # The x-component of the vertex, or nil if ChainShape:setNextVertex hasn't been called.
+---@return number y # The y-component of the vertex, or nil if ChainShape:setNextVertex hasn't been called.
+function ChainShape:getNextVertex() end
+
+---
+---Returns a point of the shape.
+---
+---@param index number # The index of the point to return.
+---@return number x # The x-coordinate of the point.
+---@return number y # The y-coordinate of the point.
+function ChainShape:getPoint(index) end
+
+---
+---Returns all points of the shape.
+---
+---@return number x1 # The x-coordinate of the first point.
+---@return number y1 # The y-coordinate of the first point.
+---@return number x2 # The x-coordinate of the second point.
+---@return number y2 # The y-coordinate of the second point.
+function ChainShape:getPoints() end
+
+---
+---Gets the vertex that establishes a connection to the previous shape.
+---
+---Setting next and previous ChainShape vertices can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@return number x # The x-component of the vertex, or nil if ChainShape:setPreviousVertex hasn't been called.
+---@return number y # The y-component of the vertex, or nil if ChainShape:setPreviousVertex hasn't been called.
+function ChainShape:getPreviousVertex() end
+
+---
+---Returns the number of vertices the shape has.
+---
+---@return number count # The number of vertices.
+function ChainShape:getVertexCount() end
+
+---
+---Sets a vertex that establishes a connection to the next shape.
+---
+---This can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@param x number # The x-component of the vertex.
+---@param y number # The y-component of the vertex.
+function ChainShape:setNextVertex(x, y) end
+
+---
+---Sets a vertex that establishes a connection to the previous shape.
+---
+---This can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@param x number # The x-component of the vertex.
+---@param y number # The y-component of the vertex.
+function ChainShape:setPreviousVertex(x, y) end
+
+---@class love.physics.CircleShape: love.physics.Shape, love.physics.Object
+local CircleShape = {}
+
+---
+---Gets the center point of the circle shape.
+---
+---@return number x # The x-component of the center point of the circle.
+---@return number y # The y-component of the center point of the circle.
+function CircleShape:getPoint() end
+
+---
+---Gets the radius of the circle shape.
+---
+---@return number radius # The radius of the circle
+function CircleShape:getRadius() end
+
+---
+---Sets the location of the center of the circle shape.
+---
+---@param x number # The x-component of the new center point of the circle.
+---@param y number # The y-component of the new center point of the circle.
+function CircleShape:setPoint(x, y) end
+
+---
+---Sets the radius of the circle.
+---
+---@param radius number # The radius of the circle
+function CircleShape:setRadius(radius) end
+
+---@class love.physics.Contact: love.physics.Object
+local Contact = {}
+
+---
+---Gets the two Fixtures that hold the shapes that are in contact.
+---
+---@return love.physics.Fixture fixtureA # The first Fixture.
+---@return love.physics.Fixture fixtureB # The second Fixture.
+function Contact:getFixtures() end
+
+---
+---Get the friction between two shapes that are in contact.
+---
+---@return number friction # The friction of the contact.
+function Contact:getFriction() end
+
+---
+---Get the normal vector between two shapes that are in contact.
+---
+---This function returns the coordinates of a unit vector that points from the first shape to the second.
+---
+---@return number nx # The x component of the normal vector.
+---@return number ny # The y component of the normal vector.
+function Contact:getNormal() end
+
+---
+---Returns the contact points of the two colliding fixtures. There can be one or two points.
+---
+---@return number x1 # The x coordinate of the first contact point.
+---@return number y1 # The y coordinate of the first contact point.
+---@return number x2 # The x coordinate of the second contact point.
+---@return number y2 # The y coordinate of the second contact point.
+function Contact:getPositions() end
+
+---
+---Get the restitution between two shapes that are in contact.
+---
+---@return number restitution # The restitution between the two shapes.
+function Contact:getRestitution() end
+
+---
+---Returns whether the contact is enabled. The collision will be ignored if a contact gets disabled in the preSolve callback.
+---
+---@return boolean enabled # True if enabled, false otherwise.
+function Contact:isEnabled() end
+
+---
+---Returns whether the two colliding fixtures are touching each other.
+---
+---@return boolean touching # True if they touch or false if not.
+function Contact:isTouching() end
+
+---
+---Resets the contact friction to the mixture value of both fixtures.
+---
+function Contact:resetFriction() end
+
+---
+---Resets the contact restitution to the mixture value of both fixtures.
+---
+function Contact:resetRestitution() end
+
+---
+---Enables or disables the contact.
+---
+---@param enabled boolean # True to enable or false to disable.
+function Contact:setEnabled(enabled) end
+
+---
+---Sets the contact friction.
+---
+---@param friction number # The contact friction.
+function Contact:setFriction(friction) end
+
+---
+---Sets the contact restitution.
+---
+---@param restitution number # The contact restitution.
+function Contact:setRestitution(restitution) end
+
+---@class love.physics.DistanceJoint: love.physics.Joint, love.physics.Object
+local DistanceJoint = {}
+
+---
+---Gets the damping ratio.
+---
+---@return number ratio # The damping ratio.
+function DistanceJoint:getDampingRatio() end
+
+---
+---Gets the response speed.
+---
+---@return number Hz # The response speed.
+function DistanceJoint:getFrequency() end
+
+---
+---Gets the equilibrium distance between the two Bodies.
+---
+---@return number l # The length between the two Bodies.
+function DistanceJoint:getLength() end
+
+---
+---Sets the damping ratio.
+---
+---@param ratio number # The damping ratio.
+function DistanceJoint:setDampingRatio(ratio) end
+
+---
+---Sets the response speed.
+---
+---@param Hz number # The response speed.
+function DistanceJoint:setFrequency(Hz) end
+
+---
+---Sets the equilibrium distance between the two Bodies.
+---
+---@param l number # The length between the two Bodies.
+function DistanceJoint:setLength(l) end
+
+---@class love.physics.EdgeShape: love.physics.Shape, love.physics.Object
+local EdgeShape = {}
+
+---
+---Gets the vertex that establishes a connection to the next shape.
+---
+---Setting next and previous EdgeShape vertices can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@return number x # The x-component of the vertex, or nil if EdgeShape:setNextVertex hasn't been called.
+---@return number y # The y-component of the vertex, or nil if EdgeShape:setNextVertex hasn't been called.
+function EdgeShape:getNextVertex() end
+
+---
+---Returns the local coordinates of the edge points.
+---
+---@return number x1 # The x-component of the first vertex.
+---@return number y1 # The y-component of the first vertex.
+---@return number x2 # The x-component of the second vertex.
+---@return number y2 # The y-component of the second vertex.
+function EdgeShape:getPoints() end
+
+---
+---Gets the vertex that establishes a connection to the previous shape.
+---
+---Setting next and previous EdgeShape vertices can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@return number x # The x-component of the vertex, or nil if EdgeShape:setPreviousVertex hasn't been called.
+---@return number y # The y-component of the vertex, or nil if EdgeShape:setPreviousVertex hasn't been called.
+function EdgeShape:getPreviousVertex() end
+
+---
+---Sets a vertex that establishes a connection to the next shape.
+---
+---This can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@param x number # The x-component of the vertex.
+---@param y number # The y-component of the vertex.
+function EdgeShape:setNextVertex(x, y) end
+
+---
+---Sets a vertex that establishes a connection to the previous shape.
+---
+---This can help prevent unwanted collisions when a flat shape slides along the edge and moves over to the new shape.
+---
+---@param x number # The x-component of the vertex.
+---@param y number # The y-component of the vertex.
+function EdgeShape:setPreviousVertex(x, y) end
+
+---@class love.physics.Fixture: love.physics.Object
+local Fixture = {}
+
+---
+---Destroys the fixture.
+---
+function Fixture:destroy() end
+
+---
+---Returns the body to which the fixture is attached.
+---
+---@return love.physics.Body body # The parent body.
+function Fixture:getBody() end
+
+---
+---Returns the points of the fixture bounding box. In case the fixture has multiple children a 1-based index can be specified. For example, a fixture will have multiple children with a chain shape.
+---
+---@param index number # A bounding box of the fixture.
+---@return number topLeftX # The x position of the top-left point.
+---@return number topLeftY # The y position of the top-left point.
+---@return number bottomRightX # The x position of the bottom-right point.
+---@return number bottomRightY # The y position of the bottom-right point.
+function Fixture:getBoundingBox(index) end
+
+---
+---Returns the categories the fixture belongs to.
+---
+---@return number category1 # The first category.
+---@return number category2 # The second category.
+function Fixture:getCategory() end
+
+---
+---Returns the density of the fixture.
+---
+---@return number density # The fixture density in kilograms per square meter.
+function Fixture:getDensity() end
+
+---
+---Returns the filter data of the fixture.
+---
+---Categories and masks are encoded as the bits of a 16-bit integer.
+---
+---@return number categories # The categories as an integer from 0 to 65535.
+---@return number mask # The mask as an integer from 0 to 65535.
+---@return number group # The group as an integer from -32768 to 32767.
+function Fixture:getFilterData() end
+
+---
+---Returns the friction of the fixture.
+---
+---@return number friction # The fixture friction.
+function Fixture:getFriction() end
+
+---
+---Returns the group the fixture belongs to. Fixtures with the same group will always collide if the group is positive or never collide if it's negative. The group zero means no group.
+---
+---The groups range from -32768 to 32767.
+---
+---@return number group # The group of the fixture.
+function Fixture:getGroupIndex() end
+
+---
+---Returns which categories this fixture should '''NOT''' collide with.
+---
+---@return number mask1 # The first category selected by the mask.
+---@return number mask2 # The second category selected by the mask.
+function Fixture:getMask() end
+
+---
+---Returns the mass, its center and the rotational inertia.
+---
+---@return number x # The x position of the center of mass.
+---@return number y # The y position of the center of mass.
+---@return number mass # The mass of the fixture.
+---@return number inertia # The rotational inertia.
+function Fixture:getMassData() end
+
+---
+---Returns the restitution of the fixture.
+---
+---@return number restitution # The fixture restitution.
+function Fixture:getRestitution() end
+
+---
+---Returns the shape of the fixture. This shape is a reference to the actual data used in the simulation. It's possible to change its values between timesteps.
+---
+---@return love.physics.Shape shape # The fixture's shape.
+function Fixture:getShape() end
+
+---
+---Returns the Lua value associated with this fixture.
+---
+---@return love.physics.any value # The Lua value associated with the fixture.
+function Fixture:getUserData() end
+
+---
+---Gets whether the Fixture is destroyed. Destroyed fixtures cannot be used.
+---
+---@return boolean destroyed # Whether the Fixture is destroyed.
+function Fixture:isDestroyed() end
+
+---
+---Returns whether the fixture is a sensor.
+---
+---@return boolean sensor # If the fixture is a sensor.
+function Fixture:isSensor() end
+
+---
+---Casts a ray against the shape of the fixture and returns the surface normal vector and the line position where the ray hit. If the ray missed the shape, nil will be returned.
+---
+---The ray starts on the first point of the input line and goes towards the second point of the line. The fifth argument is the maximum distance the ray is going to travel as a scale factor of the input line length.
+---
+---The childIndex parameter is used to specify which child of a parent shape, such as a ChainShape, will be ray casted. For ChainShapes, the index of 1 is the first edge on the chain. Ray casting a parent shape will only test the child specified so if you want to test every shape of the parent, you must loop through all of its children.
+---
+---The world position of the impact can be calculated by multiplying the line vector with the third return value and adding it to the line starting point.
+---
+---hitx, hity = x1 + (x2 - x1) * fraction, y1 + (y2 - y1) * fraction
+---
+---@param x1 number # The x position of the input line starting point.
+---@param y1 number # The y position of the input line starting point.
+---@param x2 number # The x position of the input line end point.
+---@param y2 number # The y position of the input line end point.
+---@param maxFraction number # Ray length parameter.
+---@param childIndex number # The index of the child the ray gets cast against.
+---@return number xn # The x component of the normal vector of the edge where the ray hit the shape.
+---@return number yn # The y component of the normal vector of the edge where the ray hit the shape.
+---@return number fraction # The position on the input line where the intersection happened as a factor of the line length.
+function Fixture:rayCast(x1, y1, x2, y2, maxFraction, childIndex) end
+
+---
+---Sets the categories the fixture belongs to. There can be up to 16 categories represented as a number from 1 to 16.
+---
+---All fixture's default category is 1.
+---
+---@param category1 number # The first category.
+---@param category2 number # The second category.
+function Fixture:setCategory(category1, category2) end
+
+---
+---Sets the density of the fixture. Call Body:resetMassData if this needs to take effect immediately.
+---
+---@param density number # The fixture density in kilograms per square meter.
+function Fixture:setDensity(density) end
+
+---
+---Sets the filter data of the fixture.
+---
+---Groups, categories, and mask can be used to define the collision behaviour of the fixture.
+---
+---If two fixtures are in the same group they either always collide if the group is positive, or never collide if it's negative. If the group is zero or they do not match, then the contact filter checks if the fixtures select a category of the other fixture with their masks. The fixtures do not collide if that's not the case. If they do have each other's categories selected, the return value of the custom contact filter will be used. They always collide if none was set.
+---
+---There can be up to 16 categories. Categories and masks are encoded as the bits of a 16-bit integer.
+---
+---When created, prior to calling this function, all fixtures have category set to 1, mask set to 65535 (all categories) and group set to 0.
+---
+---This function allows setting all filter data for a fixture at once. To set only the categories, the mask or the group, you can use Fixture:setCategory, Fixture:setMask or Fixture:setGroupIndex respectively.
+---
+---@param categories number # The categories as an integer from 0 to 65535.
+---@param mask number # The mask as an integer from 0 to 65535.
+---@param group number # The group as an integer from -32768 to 32767.
+function Fixture:setFilterData(categories, mask, group) end
+
+---
+---Sets the friction of the fixture.
+---
+---Friction determines how shapes react when they 'slide' along other shapes. Low friction indicates a slippery surface, like ice, while high friction indicates a rough surface, like concrete. Range: 0.0 - 1.0.
+---
+---@param friction number # The fixture friction.
+function Fixture:setFriction(friction) end
+
+---
+---Sets the group the fixture belongs to. Fixtures with the same group will always collide if the group is positive or never collide if it's negative. The group zero means no group.
+---
+---The groups range from -32768 to 32767.
+---
+---@param group number # The group as an integer from -32768 to 32767.
+function Fixture:setGroupIndex(group) end
+
+---
+---Sets the category mask of the fixture. There can be up to 16 categories represented as a number from 1 to 16.
+---
+---This fixture will '''NOT''' collide with the fixtures that are in the selected categories if the other fixture also has a category of this fixture selected.
+---
+---@param mask1 number # The first category.
+---@param mask2 number # The second category.
+function Fixture:setMask(mask1, mask2) end
+
+---
+---Sets the restitution of the fixture.
+---
+---@param restitution number # The fixture restitution.
+function Fixture:setRestitution(restitution) end
+
+---
+---Sets whether the fixture should act as a sensor.
+---
+---Sensors do not cause collision responses, but the begin-contact and end-contact World callbacks will still be called for this fixture.
+---
+---@param sensor boolean # The sensor status.
+function Fixture:setSensor(sensor) end
+
+---
+---Associates a Lua value with the fixture.
+---
+---To delete the reference, explicitly pass nil.
+---
+---@param value love.physics.any # The Lua value to associate with the fixture.
+function Fixture:setUserData(value) end
+
+---
+---Checks if a point is inside the shape of the fixture.
+---
+---@param x number # The x position of the point.
+---@param y number # The y position of the point.
+---@return boolean isInside # True if the point is inside or false if it is outside.
+function Fixture:testPoint(x, y) end
+
+---@class love.physics.FrictionJoint: love.physics.Joint, love.physics.Object
+local FrictionJoint = {}
+
+---
+---Gets the maximum friction force in Newtons.
+---
+---@return number force # Maximum force in Newtons.
+function FrictionJoint:getMaxForce() end
+
+---
+---Gets the maximum friction torque in Newton-meters.
+---
+---@return number torque # Maximum torque in Newton-meters.
+function FrictionJoint:getMaxTorque() end
+
+---
+---Sets the maximum friction force in Newtons.
+---
+---@param maxForce number # Max force in Newtons.
+function FrictionJoint:setMaxForce(maxForce) end
+
+---
+---Sets the maximum friction torque in Newton-meters.
+---
+---@param torque number # Maximum torque in Newton-meters.
+function FrictionJoint:setMaxTorque(torque) end
+
+---@class love.physics.GearJoint: love.physics.Joint, love.physics.Object
+local GearJoint = {}
+
+---
+---Get the Joints connected by this GearJoint.
+---
+---@return love.physics.Joint joint1 # The first connected Joint.
+---@return love.physics.Joint joint2 # The second connected Joint.
+function GearJoint:getJoints() end
+
+---
+---Get the ratio of a gear joint.
+---
+---@return number ratio # The ratio of the joint.
+function GearJoint:getRatio() end
+
+---
+---Set the ratio of a gear joint.
+---
+---@param ratio number # The new ratio of the joint.
+function GearJoint:setRatio(ratio) end
+
+---@class love.physics.Joint: love.physics.Object
+local Joint = {}
+
+---
+---Explicitly destroys the Joint. An error will occur if you attempt to use the object after calling this function.
+---
+---In 0.7.2, when you don't have time to wait for garbage collection, this function
+---
+---may be used to free the object immediately.
+---
+function Joint:destroy() end
+
+---
+---Get the anchor points of the joint.
+---
+---@return number x1 # The x-component of the anchor on Body 1.
+---@return number y1 # The y-component of the anchor on Body 1.
+---@return number x2 # The x-component of the anchor on Body 2.
+---@return number y2 # The y-component of the anchor on Body 2.
+function Joint:getAnchors() end
+
+---
+---Gets the bodies that the Joint is attached to.
+---
+---@return love.physics.Body bodyA # The first Body.
+---@return love.physics.Body bodyB # The second Body.
+function Joint:getBodies() end
+
+---
+---Gets whether the connected Bodies collide.
+---
+---@return boolean c # True if they collide, false otherwise.
+function Joint:getCollideConnected() end
+
+---
+---Returns the reaction force in newtons on the second body
+---
+---@param x number # How long the force applies. Usually the inverse time step or 1/dt.
+---@return number x # The x-component of the force.
+---@return number y # The y-component of the force.
+function Joint:getReactionForce(x) end
+
+---
+---Returns the reaction torque on the second body.
+---
+---@param invdt number # How long the force applies. Usually the inverse time step or 1/dt.
+---@return number torque # The reaction torque on the second body.
+function Joint:getReactionTorque(invdt) end
+
+---
+---Gets a string representing the type.
+---
+---@return love.physics.JointType type # A string with the name of the Joint type.
+function Joint:getType() end
+
+---
+---Returns the Lua value associated with this Joint.
+---
+---@return love.physics.any value # The Lua value associated with the Joint.
+function Joint:getUserData() end
+
+---
+---Gets whether the Joint is destroyed. Destroyed joints cannot be used.
+---
+---@return boolean destroyed # Whether the Joint is destroyed.
+function Joint:isDestroyed() end
+
+---
+---Associates a Lua value with the Joint.
+---
+---To delete the reference, explicitly pass nil.
+---
+---@param value love.physics.any # The Lua value to associate with the Joint.
+function Joint:setUserData(value) end
+
+---@class love.physics.MotorJoint: love.physics.Joint, love.physics.Object
+local MotorJoint = {}
+
+---
+---Gets the target angular offset between the two Bodies the Joint is attached to.
+---
+---@return number angleoffset # The target angular offset in radians: the second body's angle minus the first body's angle.
+function MotorJoint:getAngularOffset() end
+
+---
+---Gets the target linear offset between the two Bodies the Joint is attached to.
+---
+---@return number x # The x component of the target linear offset, relative to the first Body.
+---@return number y # The y component of the target linear offset, relative to the first Body.
+function MotorJoint:getLinearOffset() end
+
+---
+---Sets the target angluar offset between the two Bodies the Joint is attached to.
+---
+---@param angleoffset number # The target angular offset in radians: the second body's angle minus the first body's angle.
+function MotorJoint:setAngularOffset(angleoffset) end
+
+---
+---Sets the target linear offset between the two Bodies the Joint is attached to.
+---
+---@param x number # The x component of the target linear offset, relative to the first Body.
+---@param y number # The y component of the target linear offset, relative to the first Body.
+function MotorJoint:setLinearOffset(x, y) end
+
+---@class love.physics.MouseJoint: love.physics.Joint, love.physics.Object
+local MouseJoint = {}
+
+---
+---Returns the damping ratio.
+---
+---@return number ratio # The new damping ratio.
+function MouseJoint:getDampingRatio() end
+
+---
+---Returns the frequency.
+---
+---@return number freq # The frequency in hertz.
+function MouseJoint:getFrequency() end
+
+---
+---Gets the highest allowed force.
+---
+---@return number f # The max allowed force.
+function MouseJoint:getMaxForce() end
+
+---
+---Gets the target point.
+---
+---@return number x # The x-component of the target.
+---@return number y # The x-component of the target.
+function MouseJoint:getTarget() end
+
+---
+---Sets a new damping ratio.
+---
+---@param ratio number # The new damping ratio.
+function MouseJoint:setDampingRatio(ratio) end
+
+---
+---Sets a new frequency.
+---
+---@param freq number # The new frequency in hertz.
+function MouseJoint:setFrequency(freq) end
+
+---
+---Sets the highest allowed force.
+---
+---@param f number # The max allowed force.
+function MouseJoint:setMaxForce(f) end
+
+---
+---Sets the target point.
+---
+---@param x number # The x-component of the target.
+---@param y number # The y-component of the target.
+function MouseJoint:setTarget(x, y) end
+
+---@class love.physics.PolygonShape: love.physics.Shape, love.physics.Object
+local PolygonShape = {}
+
+---
+---Get the local coordinates of the polygon's vertices.
+---
+---This function has a variable number of return values. It can be used in a nested fashion with love.graphics.polygon.
+---
+---@return number x1 # The x-component of the first vertex.
+---@return number y1 # The y-component of the first vertex.
+---@return number x2 # The x-component of the second vertex.
+---@return number y2 # The y-component of the second vertex.
+function PolygonShape:getPoints() end
+
+---@class love.physics.PrismaticJoint: love.physics.Joint, love.physics.Object
+local PrismaticJoint = {}
+
+---
+---Checks whether the limits are enabled.
+---
+---@return boolean enabled # True if enabled, false otherwise.
+function PrismaticJoint:areLimitsEnabled() end
+
+---
+---Gets the world-space axis vector of the Prismatic Joint.
+---
+---@return number x # The x-axis coordinate of the world-space axis vector.
+---@return number y # The y-axis coordinate of the world-space axis vector.
+function PrismaticJoint:getAxis() end
+
+---
+---Get the current joint angle speed.
+---
+---@return number s # Joint angle speed in meters/second.
+function PrismaticJoint:getJointSpeed() end
+
+---
+---Get the current joint translation.
+---
+---@return number t # Joint translation, usually in meters..
+function PrismaticJoint:getJointTranslation() end
+
+---
+---Gets the joint limits.
+---
+---@return number lower # The lower limit, usually in meters.
+---@return number upper # The upper limit, usually in meters.
+function PrismaticJoint:getLimits() end
+
+---
+---Gets the lower limit.
+---
+---@return number lower # The lower limit, usually in meters.
+function PrismaticJoint:getLowerLimit() end
+
+---
+---Gets the maximum motor force.
+---
+---@return number f # The maximum motor force, usually in N.
+function PrismaticJoint:getMaxMotorForce() end
+
+---
+---Returns the current motor force.
+---
+---@param invdt number # How long the force applies. Usually the inverse time step or 1/dt.
+---@return number force # The force on the motor in newtons.
+function PrismaticJoint:getMotorForce(invdt) end
+
+---
+---Gets the motor speed.
+---
+---@return number s # The motor speed, usually in meters per second.
+function PrismaticJoint:getMotorSpeed() end
+
+---
+---Gets the upper limit.
+---
+---@return number upper # The upper limit, usually in meters.
+function PrismaticJoint:getUpperLimit() end
+
+---
+---Checks whether the motor is enabled.
+---
+---@return boolean enabled # True if enabled, false if disabled.
+function PrismaticJoint:isMotorEnabled() end
+
+---
+---Sets the limits.
+---
+---@param lower number # The lower limit, usually in meters.
+---@param upper number # The upper limit, usually in meters.
+function PrismaticJoint:setLimits(lower, upper) end
+
+---
+---Enables/disables the joint limit.
+---
+---@return boolean enable # True if enabled, false if disabled.
+function PrismaticJoint:setLimitsEnabled() end
+
+---
+---Sets the lower limit.
+---
+---@param lower number # The lower limit, usually in meters.
+function PrismaticJoint:setLowerLimit(lower) end
+
+---
+---Set the maximum motor force.
+---
+---@param f number # The maximum motor force, usually in N.
+function PrismaticJoint:setMaxMotorForce(f) end
+
+---
+---Enables/disables the joint motor.
+---
+---@param enable boolean # True to enable, false to disable.
+function PrismaticJoint:setMotorEnabled(enable) end
+
+---
+---Sets the motor speed.
+---
+---@param s number # The motor speed, usually in meters per second.
+function PrismaticJoint:setMotorSpeed(s) end
+
+---
+---Sets the upper limit.
+---
+---@param upper number # The upper limit, usually in meters.
+function PrismaticJoint:setUpperLimit(upper) end
+
+---@class love.physics.PulleyJoint: love.physics.Joint, love.physics.Object
+local PulleyJoint = {}
+
+---
+---Get the total length of the rope.
+---
+---@return number length # The length of the rope in the joint.
+function PulleyJoint:getConstant() end
+
+---
+---Get the ground anchor positions in world coordinates.
+---
+---@return number a1x # The x coordinate of the first anchor.
+---@return number a1y # The y coordinate of the first anchor.
+---@return number a2x # The x coordinate of the second anchor.
+---@return number a2y # The y coordinate of the second anchor.
+function PulleyJoint:getGroundAnchors() end
+
+---
+---Get the current length of the rope segment attached to the first body.
+---
+---@return number length # The length of the rope segment.
+function PulleyJoint:getLengthA() end
+
+---
+---Get the current length of the rope segment attached to the second body.
+---
+---@return number length # The length of the rope segment.
+function PulleyJoint:getLengthB() end
+
+---
+---Get the maximum lengths of the rope segments.
+---
+---@return number len1 # The maximum length of the first rope segment.
+---@return number len2 # The maximum length of the second rope segment.
+function PulleyJoint:getMaxLengths() end
+
+---
+---Get the pulley ratio.
+---
+---@return number ratio # The pulley ratio of the joint.
+function PulleyJoint:getRatio() end
+
+---
+---Set the total length of the rope.
+---
+---Setting a new length for the rope updates the maximum length values of the joint.
+---
+---@param length number # The new length of the rope in the joint.
+function PulleyJoint:setConstant(length) end
+
+---
+---Set the maximum lengths of the rope segments.
+---
+---The physics module also imposes maximum values for the rope segments. If the parameters exceed these values, the maximum values are set instead of the requested values.
+---
+---@param max1 number # The new maximum length of the first segment.
+---@param max2 number # The new maximum length of the second segment.
+function PulleyJoint:setMaxLengths(max1, max2) end
+
+---
+---Set the pulley ratio.
+---
+---@param ratio number # The new pulley ratio of the joint.
+function PulleyJoint:setRatio(ratio) end
+
+---@class love.physics.RevoluteJoint: love.physics.Joint, love.physics.Object
+local RevoluteJoint = {}
+
+---
+---Checks whether limits are enabled.
+---
+---@return boolean enabled # True if enabled, false otherwise.
+function RevoluteJoint:areLimitsEnabled() end
+
+---
+---Get the current joint angle.
+---
+---@return number angle # The joint angle in radians.
+function RevoluteJoint:getJointAngle() end
+
+---
+---Get the current joint angle speed.
+---
+---@return number s # Joint angle speed in radians/second.
+function RevoluteJoint:getJointSpeed() end
+
+---
+---Gets the joint limits.
+---
+---@return number lower # The lower limit, in radians.
+---@return number upper # The upper limit, in radians.
+function RevoluteJoint:getLimits() end
+
+---
+---Gets the lower limit.
+---
+---@return number lower # The lower limit, in radians.
+function RevoluteJoint:getLowerLimit() end
+
+---
+---Gets the maximum motor force.
+---
+---@return number f # The maximum motor force, in Nm.
+function RevoluteJoint:getMaxMotorTorque() end
+
+---
+---Gets the motor speed.
+---
+---@return number s # The motor speed, radians per second.
+function RevoluteJoint:getMotorSpeed() end
+
+---
+---Get the current motor force.
+---
+---@return number f # The current motor force, in Nm.
+function RevoluteJoint:getMotorTorque() end
+
+---
+---Gets the upper limit.
+---
+---@return number upper # The upper limit, in radians.
+function RevoluteJoint:getUpperLimit() end
+
+---
+---Checks whether limits are enabled.
+---
+---@return boolean enabled # True if enabled, false otherwise.
+function RevoluteJoint:hasLimitsEnabled() end
+
+---
+---Checks whether the motor is enabled.
+---
+---@return boolean enabled # True if enabled, false if disabled.
+function RevoluteJoint:isMotorEnabled() end
+
+---
+---Sets the limits.
+---
+---@param lower number # The lower limit, in radians.
+---@param upper number # The upper limit, in radians.
+function RevoluteJoint:setLimits(lower, upper) end
+
+---
+---Enables/disables the joint limit.
+---
+---@param enable boolean # True to enable, false to disable.
+function RevoluteJoint:setLimitsEnabled(enable) end
+
+---
+---Sets the lower limit.
+---
+---@param lower number # The lower limit, in radians.
+function RevoluteJoint:setLowerLimit(lower) end
+
+---
+---Set the maximum motor force.
+---
+---@param f number # The maximum motor force, in Nm.
+function RevoluteJoint:setMaxMotorTorque(f) end
+
+---
+---Enables/disables the joint motor.
+---
+---@param enable boolean # True to enable, false to disable.
+function RevoluteJoint:setMotorEnabled(enable) end
+
+---
+---Sets the motor speed.
+---
+---@param s number # The motor speed, radians per second.
+function RevoluteJoint:setMotorSpeed(s) end
+
+---
+---Sets the upper limit.
+---
+---@param upper number # The upper limit, in radians.
+function RevoluteJoint:setUpperLimit(upper) end
+
+---@class love.physics.RopeJoint: love.physics.Joint, love.physics.Object
+local RopeJoint = {}
+
+---
+---Gets the maximum length of a RopeJoint.
+---
+---@return number maxLength # The maximum length of the RopeJoint.
+function RopeJoint:getMaxLength() end
+
+---
+---Sets the maximum length of a RopeJoint.
+---
+---@param maxLength number # The new maximum length of the RopeJoint.
+function RopeJoint:setMaxLength(maxLength) end
+
+---@class love.physics.Shape: love.physics.Object
+local Shape = {}
+
+---
+---Returns the points of the bounding box for the transformed shape.
+---
+---@param tx number # The translation of the shape on the x-axis.
+---@param ty number # The translation of the shape on the y-axis.
+---@param tr number # The shape rotation.
+---@param childIndex number # The index of the child to compute the bounding box of.
+---@return number topLeftX # The x position of the top-left point.
+---@return number topLeftY # The y position of the top-left point.
+---@return number bottomRightX # The x position of the bottom-right point.
+---@return number bottomRightY # The y position of the bottom-right point.
+function Shape:computeAABB(tx, ty, tr, childIndex) end
+
+---
+---Computes the mass properties for the shape with the specified density.
+---
+---@param density number # The shape density.
+---@return number x # The x postition of the center of mass.
+---@return number y # The y postition of the center of mass.
+---@return number mass # The mass of the shape.
+---@return number inertia # The rotational inertia.
+function Shape:computeMass(density) end
+
+---
+---Returns the number of children the shape has.
+---
+---@return number count # The number of children.
+function Shape:getChildCount() end
+
+---
+---Gets the radius of the shape.
+---
+---@return number radius # The radius of the shape.
+function Shape:getRadius() end
+
+---
+---Gets a string representing the Shape.
+---
+---This function can be useful for conditional debug drawing.
+---
+---@return love.physics.ShapeType type # The type of the Shape.
+function Shape:getType() end
+
+---
+---Casts a ray against the shape and returns the surface normal vector and the line position where the ray hit. If the ray missed the shape, nil will be returned. The Shape can be transformed to get it into the desired position.
+---
+---The ray starts on the first point of the input line and goes towards the second point of the line. The fourth argument is the maximum distance the ray is going to travel as a scale factor of the input line length.
+---
+---The childIndex parameter is used to specify which child of a parent shape, such as a ChainShape, will be ray casted. For ChainShapes, the index of 1 is the first edge on the chain. Ray casting a parent shape will only test the child specified so if you want to test every shape of the parent, you must loop through all of its children.
+---
+---The world position of the impact can be calculated by multiplying the line vector with the third return value and adding it to the line starting point.
+---
+---hitx, hity = x1 + (x2 - x1) * fraction, y1 + (y2 - y1) * fraction
+---
+---@param x1 number # The x position of the input line starting point.
+---@param y1 number # The y position of the input line starting point.
+---@param x2 number # The x position of the input line end point.
+---@param y2 number # The y position of the input line end point.
+---@param maxFraction number # Ray length parameter.
+---@param tx number # The translation of the shape on the x-axis.
+---@param ty number # The translation of the shape on the y-axis.
+---@param tr number # The shape rotation.
+---@param childIndex number # The index of the child the ray gets cast against.
+---@return number xn # The x component of the normal vector of the edge where the ray hit the shape.
+---@return number yn # The y component of the normal vector of the edge where the ray hit the shape.
+---@return number fraction # The position on the input line where the intersection happened as a factor of the line length.
+function Shape:rayCast(x1, y1, x2, y2, maxFraction, tx, ty, tr, childIndex) end
+
+---
+---This is particularly useful for mouse interaction with the shapes. By looping through all shapes and testing the mouse position with this function, we can find which shapes the mouse touches.
+---
+---@param tx number # Translates the shape along the x-axis.
+---@param ty number # Translates the shape along the y-axis.
+---@param tr number # Rotates the shape.
+---@param x number # The x-component of the point.
+---@param y number # The y-component of the point.
+---@return boolean hit # True if inside, false if outside
+function Shape:testPoint(tx, ty, tr, x, y) end
+
+---@class love.physics.WeldJoint: love.physics.Joint, love.physics.Object
+local WeldJoint = {}
+
+---
+---Returns the damping ratio of the joint.
+---
+---@return number ratio # The damping ratio.
+function WeldJoint:getDampingRatio() end
+
+---
+---Returns the frequency.
+---
+---@return number freq # The frequency in hertz.
+function WeldJoint:getFrequency() end
+
+---
+---Sets a new damping ratio.
+---
+---@param ratio number # The new damping ratio.
+function WeldJoint:setDampingRatio(ratio) end
+
+---
+---Sets a new frequency.
+---
+---@param freq number # The new frequency in hertz.
+function WeldJoint:setFrequency(freq) end
+
+---@class love.physics.WheelJoint: love.physics.Joint, love.physics.Object
+local WheelJoint = {}
+
+---
+---Gets the world-space axis vector of the Wheel Joint.
+---
+---@return number x # The x-axis coordinate of the world-space axis vector.
+---@return number y # The y-axis coordinate of the world-space axis vector.
+function WheelJoint:getAxis() end
+
+---
+---Returns the current joint translation speed.
+---
+---@return number speed # The translation speed of the joint in meters per second.
+function WheelJoint:getJointSpeed() end
+
+---
+---Returns the current joint translation.
+---
+---@return number position # The translation of the joint in meters.
+function WheelJoint:getJointTranslation() end
+
+---
+---Returns the maximum motor torque.
+---
+---@return number maxTorque # The maximum torque of the joint motor in newton meters.
+function WheelJoint:getMaxMotorTorque() end
+
+---
+---Returns the speed of the motor.
+---
+---@return number speed # The speed of the joint motor in radians per second.
+function WheelJoint:getMotorSpeed() end
+
+---
+---Returns the current torque on the motor.
+---
+---@param invdt number # How long the force applies. Usually the inverse time step or 1/dt.
+---@return number torque # The torque on the motor in newton meters.
+function WheelJoint:getMotorTorque(invdt) end
+
+---
+---Returns the damping ratio.
+---
+---@return number ratio # The damping ratio.
+function WheelJoint:getSpringDampingRatio() end
+
+---
+---Returns the spring frequency.
+---
+---@return number freq # The frequency in hertz.
+function WheelJoint:getSpringFrequency() end
+
+---
+---Sets a new maximum motor torque.
+---
+---@param maxTorque number # The new maximum torque for the joint motor in newton meters.
+function WheelJoint:setMaxMotorTorque(maxTorque) end
+
+---
+---Starts and stops the joint motor.
+---
+---@param enable boolean # True turns the motor on and false turns it off.
+function WheelJoint:setMotorEnabled(enable) end
+
+---
+---Sets a new speed for the motor.
+---
+---@param speed number # The new speed for the joint motor in radians per second.
+function WheelJoint:setMotorSpeed(speed) end
+
+---
+---Sets a new damping ratio.
+---
+---@param ratio number # The new damping ratio.
+function WheelJoint:setSpringDampingRatio(ratio) end
+
+---
+---Sets a new spring frequency.
+---
+---@param freq number # The new frequency in hertz.
+function WheelJoint:setSpringFrequency(freq) end
+
+---@class love.physics.World: love.physics.Object
+local World = {}
+
+---
+---Destroys the world, taking all bodies, joints, fixtures and their shapes with it.
+---
+---An error will occur if you attempt to use any of the destroyed objects after calling this function.
+---
+function World:destroy() end
+
+---
+---Returns a table with all bodies.
+---
+---@return table bodies # A sequence with all bodies.
+function World:getBodies() end
+
+---
+---Returns the number of bodies in the world.
+---
+---@return number n # The number of bodies in the world.
+function World:getBodyCount() end
+
+---
+---Returns functions for the callbacks during the world update.
+---
+---@return function beginContact # Gets called when two fixtures begin to overlap.
+---@return function endContact # Gets called when two fixtures cease to overlap.
+---@return function preSolve # Gets called before a collision gets resolved.
+---@return function postSolve # Gets called after the collision has been resolved.
+function World:getCallbacks() end
+
+---
+---Returns the number of contacts in the world.
+---
+---@return number n # The number of contacts in the world.
+function World:getContactCount() end
+
+---
+---Returns the function for collision filtering.
+---
+---@return function contactFilter # The function that handles the contact filtering.
+function World:getContactFilter() end
+
+---
+---Returns a table with all Contacts.
+---
+---@return table contacts # A sequence with all Contacts.
+function World:getContacts() end
+
+---
+---Get the gravity of the world.
+---
+---@return number x # The x component of gravity.
+---@return number y # The y component of gravity.
+function World:getGravity() end
+
+---
+---Returns the number of joints in the world.
+---
+---@return number n # The number of joints in the world.
+function World:getJointCount() end
+
+---
+---Returns a table with all joints.
+---
+---@return table joints # A sequence with all joints.
+function World:getJoints() end
+
+---
+---Gets whether the World is destroyed. Destroyed worlds cannot be used.
+---
+---@return boolean destroyed # Whether the World is destroyed.
+function World:isDestroyed() end
+
+---
+---Returns if the world is updating its state.
+---
+---This will return true inside the callbacks from World:setCallbacks.
+---
+---@return boolean locked # Will be true if the world is in the process of updating its state.
+function World:isLocked() end
+
+---
+---Gets the sleep behaviour of the world.
+---
+---@return boolean allow # True if bodies in the world are allowed to sleep, or false if not.
+function World:isSleepingAllowed() end
+
+---
+---Calls a function for each fixture inside the specified area by searching for any overlapping bounding box (Fixture:getBoundingBox).
+---
+---@param topLeftX number # The x position of the top-left point.
+---@param topLeftY number # The y position of the top-left point.
+---@param bottomRightX number # The x position of the bottom-right point.
+---@param bottomRightY number # The y position of the bottom-right point.
+---@param callback function # This function gets passed one argument, the fixture, and should return a boolean. The search will continue if it is true or stop if it is false.
+function World:queryBoundingBox(topLeftX, topLeftY, bottomRightX, bottomRightY, callback) end
+
+---
+---Casts a ray and calls a function for each fixtures it intersects.
+---
+---@param fixture love.physics.Fixture # The fixture intersecting the ray.
+---@param x number # The x position of the intersection point.
+---@param y number # The y position of the intersection point.
+---@param xn number # The x value of the surface normal vector of the shape edge.
+---@param yn number # The y value of the surface normal vector of the shape edge.
+---@param fraction number # The position of the intersection on the ray as a number from 0 to 1 (or even higher if the ray length was changed with the return value).
+---@return number control # The ray can be controlled with the return value. A positive value sets a new ray length where 1 is the default value. A value of 0 terminates the ray. If the callback function returns -1, the intersection gets ignored as if it didn't happen.
+function World:rayCast(fixture, x, y, xn, yn, fraction) end
+
+---
+---Sets functions for the collision callbacks during the world update.
+---
+---Four Lua functions can be given as arguments. The value nil removes a function.
+---
+---When called, each function will be passed three arguments. The first two arguments are the colliding fixtures and the third argument is the Contact between them. The postSolve callback additionally gets the normal and tangent impulse for each contact point. See notes.
+---
+---If you are interested to know when exactly each callback is called, consult a Box2d manual
+---
+---@param beginContact function # Gets called when two fixtures begin to overlap.
+---@param endContact function # Gets called when two fixtures cease to overlap. This will also be called outside of a world update, when colliding objects are destroyed.
+---@param preSolve function # Gets called before a collision gets resolved.
+---@param postSolve function # Gets called after the collision has been resolved.
+function World:setCallbacks(beginContact, endContact, preSolve, postSolve) end
+
+---
+---Sets a function for collision filtering.
+---
+---If the group and category filtering doesn't generate a collision decision, this function gets called with the two fixtures as arguments. The function should return a boolean value where true means the fixtures will collide and false means they will pass through each other.
+---
+---@param filter function # The function handling the contact filtering.
+function World:setContactFilter(filter) end
+
+---
+---Set the gravity of the world.
+---
+---@param x number # The x component of gravity.
+---@param y number # The y component of gravity.
+function World:setGravity(x, y) end
+
+---
+---Sets the sleep behaviour of the world.
+---
+---@param allow boolean # True if bodies in the world are allowed to sleep, or false if not.
+function World:setSleepingAllowed(allow) end
+
+---
+---Translates the World's origin. Useful in large worlds where floating point precision issues become noticeable at far distances from the origin.
+---
+---@param x number # The x component of the new origin with respect to the old origin.
+---@param y number # The y component of the new origin with respect to the old origin.
+function World:translateOrigin(x, y) end
+
+---
+---Update the state of the world.
+---
+---@param dt number # The time (in seconds) to advance the physics simulation.
+---@param velocityiterations number # The maximum number of steps used to determine the new velocities when resolving a collision.
+---@param positioniterations number # The maximum number of steps used to determine the new positions when resolving a collision.
+function World:update(dt, velocityiterations, positioniterations) end
diff --git a/meta/3rd/love2d/library/love.sound.lua b/meta/3rd/love2d/library/love.sound.lua
index e44eabfa..75c2923a 100644
--- a/meta/3rd/love2d/library/love.sound.lua
+++ b/meta/3rd/love2d/library/love.sound.lua
@@ -4,9 +4,9 @@ love.sound = {}
---
---Attempts to find a decoder for the encoded sound data in the specified file.
---
----@param file File # The file with encoded sound data.
+---@param file love.sound.File # The file with encoded sound data.
---@param buffer number # The size of each decoded chunk, in bytes.
----@return Decoder decoder # A new Decoder object.
+---@return love.sound.Decoder decoder # A new Decoder object.
function love.sound.newDecoder(file, buffer) end
---
@@ -15,5 +15,87 @@ function love.sound.newDecoder(file, buffer) end
---The sound data will be decoded to the memory in a raw format. It is recommended to create only short sounds like effects, as a 3 minute song uses 30 MB of memory this way.
---
---@param filename string # The file name of the file to load.
----@return SoundData soundData # A new SoundData object.
+---@return love.sound.SoundData soundData # A new SoundData object.
function love.sound.newSoundData(filename) end
+
+---@class love.sound.Decoder: love.sound.Object
+local Decoder = {}
+
+---
+---Creates a new copy of current decoder.
+---
+---The new decoder will start decoding from the beginning of the audio stream.
+---
+---@return love.sound.Decoder decoder # New copy of the decoder.
+function Decoder:clone() end
+
+---
+---Returns the number of bits per sample.
+---
+---@return number bitDepth # Either 8, or 16.
+function Decoder:getBitDepth() end
+
+---
+---Returns the number of channels in the stream.
+---
+---@return number channels # 1 for mono, 2 for stereo.
+function Decoder:getChannelCount() end
+
+---
+---Gets the duration of the sound file. It may not always be sample-accurate, and it may return -1 if the duration cannot be determined at all.
+---
+---@return number duration # The duration of the sound file in seconds, or -1 if it cannot be determined.
+function Decoder:getDuration() end
+
+---
+---Returns the sample rate of the Decoder.
+---
+---@return number rate # Number of samples per second.
+function Decoder:getSampleRate() end
+
+---@class love.sound.SoundData: love.sound.Data, love.sound.Object
+local SoundData = {}
+
+---
+---Returns the number of bits per sample.
+---
+---@return number bitdepth # Either 8, or 16.
+function SoundData:getBitDepth() end
+
+---
+---Returns the number of channels in the SoundData.
+---
+---@return number channels # 1 for mono, 2 for stereo.
+function SoundData:getChannelCount() end
+
+---
+---Gets the duration of the sound data.
+---
+---@return number duration # The duration of the sound data in seconds.
+function SoundData:getDuration() end
+
+---
+---Gets the value of the sample-point at the specified position. For stereo SoundData objects, the data from the left and right channels are interleaved in that order.
+---
+---@param i number # An integer value specifying the position of the sample (starting at 0).
+---@return number sample # The normalized samplepoint (range -1.0 to 1.0).
+function SoundData:getSample(i) end
+
+---
+---Returns the number of samples per channel of the SoundData.
+---
+---@return number count # Total number of samples.
+function SoundData:getSampleCount() end
+
+---
+---Returns the sample rate of the SoundData.
+---
+---@return number rate # Number of samples per second.
+function SoundData:getSampleRate() end
+
+---
+---Sets the value of the sample-point at the specified position. For stereo SoundData objects, the data from the left and right channels are interleaved in that order.
+---
+---@param i number # An integer value specifying the position of the sample (starting at 0).
+---@param sample number # The normalized samplepoint (range -1.0 to 1.0).
+function SoundData:setSample(i, sample) end
diff --git a/meta/3rd/love2d/library/love.system.lua b/meta/3rd/love2d/library/love.system.lua
index dfb79734..7eae76ad 100644
--- a/meta/3rd/love2d/library/love.system.lua
+++ b/meta/3rd/love2d/library/love.system.lua
@@ -16,7 +16,7 @@ function love.system.getOS() end
---
---Gets information about the system's power supply.
---
----@return PowerState state # The basic state of the power supply.
+---@return love.system.PowerState state # The basic state of the power supply.
---@return number percent # Percentage of battery life left, between 0 and 100. nil if the value can't be determined or there's no battery.
---@return number seconds # Seconds of battery life left. nil if the value can't be determined or there's no battery.
function love.system.getPowerInfo() end
diff --git a/meta/3rd/love2d/library/love.thread.lua b/meta/3rd/love2d/library/love.thread.lua
index e97aaa70..86a0325a 100644
--- a/meta/3rd/love2d/library/love.thread.lua
+++ b/meta/3rd/love2d/library/love.thread.lua
@@ -5,7 +5,7 @@ love.thread = {}
---Creates or retrieves a named thread channel.
---
---@param name string # The name of the channel you want to create or retrieve.
----@return Channel channel # The Channel object associated with the name.
+---@return love.thread.Channel channel # The Channel object associated with the name.
function love.thread.getChannel(name) end
---
@@ -13,12 +13,120 @@ function love.thread.getChannel(name) end
---
---One use for them is to pass new unnamed channels to other threads via Channel:push on a named channel.
---
----@return Channel channel # The new Channel object.
+---@return love.thread.Channel channel # The new Channel object.
function love.thread.newChannel() end
---
---Creates a new Thread from a filename, string or FileData object containing Lua code.
---
---@param filename string # The name of the Lua file to use as the source.
----@return Thread thread # A new Thread that has yet to be started.
+---@return love.thread.Thread thread # A new Thread that has yet to be started.
function love.thread.newThread(filename) end
+
+---@class love.thread.Channel: love.thread.Object
+local Channel = {}
+
+---
+---Clears all the messages in the Channel queue.
+---
+function Channel:clear() end
+
+---
+---Retrieves the value of a Channel message and removes it from the message queue.
+---
+---It waits until a message is in the queue then returns the message value.
+---
+---@return love.thread.Variant value # The contents of the message.
+function Channel:demand() end
+
+---
+---Retrieves the number of messages in the thread Channel queue.
+---
+---@return number count # The number of messages in the queue.
+function Channel:getCount() end
+
+---
+---Gets whether a pushed value has been popped or otherwise removed from the Channel.
+---
+---@param id number # An id value previously returned by Channel:push.
+---@return boolean hasread # Whether the value represented by the id has been removed from the Channel via Channel:pop, Channel:demand, or Channel:clear.
+function Channel:hasRead(id) end
+
+---
+---Retrieves the value of a Channel message, but leaves it in the queue.
+---
+---It returns nil if there's no message in the queue.
+---
+---@return love.thread.Variant value # The contents of the message.
+function Channel:peek() end
+
+---
+---Executes the specified function atomically with respect to this Channel.
+---
+---Calling multiple methods in a row on the same Channel is often useful. However if multiple Threads are calling this Channel's methods at the same time, the different calls on each Thread might end up interleaved (e.g. one or more of the second thread's calls may happen in between the first thread's calls.)
+---
+---This method avoids that issue by making sure the Thread calling the method has exclusive access to the Channel until the specified function has returned.
+---
+---@param func function # The function to call, the form of function(channel, arg1, arg2, ...) end. The Channel is passed as the first argument to the function when it is called.
+---@param arg1 love.thread.any # Additional arguments that the given function will receive when it is called.
+---@param ... love.thread.any # Additional arguments that the given function will receive when it is called.
+---@return love.thread.any ret1 # The first return value of the given function (if any.)
+---@return love.thread.any ... # Any other return values.
+function Channel:performAtomic(func, arg1, ...) end
+
+---
+---Retrieves the value of a Channel message and removes it from the message queue.
+---
+---It returns nil if there are no messages in the queue.
+---
+---@return love.thread.Variant value # The contents of the message.
+function Channel:pop() end
+
+---
+---Send a message to the thread Channel.
+---
+---See Variant for the list of supported types.
+---
+---@param value love.thread.Variant # The contents of the message.
+---@return number id # Identifier which can be supplied to Channel:hasRead
+function Channel:push(value) end
+
+---
+---Send a message to the thread Channel and wait for a thread to accept it.
+---
+---See Variant for the list of supported types.
+---
+---@param value love.thread.Variant # The contents of the message.
+---@return boolean success # Whether the message was successfully supplied (always true).
+function Channel:supply(value) end
+
+---@class love.thread.Thread: love.thread.Object
+local Thread = {}
+
+---
+---Retrieves the error string from the thread if it produced an error.
+---
+---@return string err # The error message, or nil if the Thread has not caused an error.
+function Thread:getError() end
+
+---
+---Returns whether the thread is currently running.
+---
+---Threads which are not running can be (re)started with Thread:start.
+---
+---@return boolean value # True if the thread is running, false otherwise.
+function Thread:isRunning() end
+
+---
+---Starts the thread.
+---
+---Beginning with version 0.9.0, threads can be restarted after they have completed their execution.
+---
+function Thread:start() end
+
+---
+---Wait for a thread to finish.
+---
+---This call will block until the thread finishes.
+---
+function Thread:wait() end
diff --git a/meta/3rd/love2d/library/love.touch.lua b/meta/3rd/love2d/library/love.touch.lua
index 1b9251fd..976b9f29 100644
--- a/meta/3rd/love2d/library/love.touch.lua
+++ b/meta/3rd/love2d/library/love.touch.lua
@@ -4,7 +4,7 @@ love.touch = {}
---
---Gets the current position of the specified touch-press, in pixels.
---
----@param id light userdata # The identifier of the touch-press. Use love.touch.getTouches, love.touchpressed, or love.touchmoved to obtain touch id values.
+---@param id lightuserdata # The identifier of the touch-press. Use love.touch.getTouches, love.touchpressed, or love.touchmoved to obtain touch id values.
---@return number x # The position along the x-axis of the touch-press inside the window, in pixels.
---@return number y # The position along the y-axis of the touch-press inside the window, in pixels.
function love.touch.getPosition(id) end
@@ -12,7 +12,7 @@ function love.touch.getPosition(id) end
---
---Gets the current pressure of the specified touch-press.
---
----@param id light userdata # The identifier of the touch-press. Use love.touch.getTouches, love.touchpressed, or love.touchmoved to obtain touch id values.
+---@param id lightuserdata # The identifier of the touch-press. Use love.touch.getTouches, love.touchpressed, or love.touchmoved to obtain touch id values.
---@return number pressure # The pressure of the touch-press. Most touch screens aren't pressure sensitive, in which case the pressure will be 1.
function love.touch.getPressure(id) end
diff --git a/meta/3rd/love2d/library/love.video.lua b/meta/3rd/love2d/library/love.video.lua
index a9209661..98fb0ea8 100644
--- a/meta/3rd/love2d/library/love.video.lua
+++ b/meta/3rd/love2d/library/love.video.lua
@@ -5,5 +5,8 @@ love.video = {}
---Creates a new VideoStream. Currently only Ogg Theora video files are supported. VideoStreams can't draw videos, see love.graphics.newVideo for that.
---
---@param filename string # The file path to the Ogg Theora video file.
----@return VideoStream videostream # A new VideoStream.
+---@return love.video.VideoStream videostream # A new VideoStream.
function love.video.newVideoStream(filename) end
+
+---@class love.video.VideoStream: love.video.Object
+local VideoStream = {}
diff --git a/meta/3rd/love2d/library/love.window.lua b/meta/3rd/love2d/library/love.window.lua
index 9730de69..f11e9cb1 100644
--- a/meta/3rd/love2d/library/love.window.lua
+++ b/meta/3rd/love2d/library/love.window.lua
@@ -56,14 +56,14 @@ function love.window.getDisplayName(displayindex) end
---Gets current device display orientation.
---
---@param displayindex number # Display index to get its display orientation, or nil for default display index.
----@return DisplayOrientation orientation # Current device display orientation.
+---@return love.window.DisplayOrientation orientation # Current device display orientation.
function love.window.getDisplayOrientation(displayindex) end
---
---Gets whether the window is fullscreen.
---
---@return boolean fullscreen # True if the window is fullscreen, false otherwise.
----@return FullscreenType fstype # The type of fullscreen mode used.
+---@return love.window.FullscreenType fstype # The type of fullscreen mode used.
function love.window.getFullscreen() end
---
@@ -76,7 +76,7 @@ function love.window.getFullscreenModes(displayindex) end
---
---Gets the window icon.
---
----@return ImageData imagedata # The window icon imagedata, or nil if no icon has been set with love.window.setIcon.
+---@return love.window.ImageData imagedata # The window icon imagedata, or nil if no icon has been set with love.window.setIcon.
function love.window.getIcon() end
---
@@ -209,7 +209,7 @@ function love.window.setFullscreen(fullscreen) end
---
---Sets the window icon until the game is quit. Not all operating systems support very large icon images.
---
----@param imagedata ImageData # The window icon image.
+---@param imagedata love.window.ImageData # The window icon image.
---@return boolean success # Whether the icon has been set successfully.
function love.window.setIcon(imagedata) end
@@ -253,7 +253,7 @@ function love.window.setVSync(vsync) end
---
---@param title string # The title of the message box.
---@param message string # The text inside the message box.
----@param type MessageBoxType # The type of the message box.
+---@param type love.window.MessageBoxType # The type of the message box.
---@param attachtowindow boolean # Whether the message box should be attached to the love window or free-floating.
---@return boolean success # Whether the message box was successfully displayed.
function love.window.showMessageBox(title, message, type, attachtowindow) end
diff --git a/tools/love-api.lua b/tools/love-api.lua
index 222cb558..0d751531 100644
--- a/tools/love-api.lua
+++ b/tools/love-api.lua
@@ -10,8 +10,70 @@ local metaPath = fs.path 'meta/3rd/love2d'
local libraryPath = metaPath / 'library'
fs.create_directories(libraryPath)
-local function buildType(param)
- return param.type
+local knownTypes = {
+ ['nil'] = 'nil',
+ ['boolean'] = 'boolean',
+ ['number'] = 'number',
+ ['integer'] = 'integer',
+ ['string'] = 'string',
+ ['table'] = 'table',
+ ['function'] = 'function',
+ ['userdata'] = 'userdata',
+ ['lightuserdata'] = 'lightuserdata',
+ ['thread'] = 'thread',
+ ['cdata'] = 'ffi.cdata*',
+ ['light userdata'] = 'lightuserdata'
+}
+
+local function getTypeName(class, name)
+ if knownTypes[name] then
+ return knownTypes[name]
+ end
+ return class .. '.' .. name
+end
+
+local function buildType(class, param)
+ return getTypeName(class, param.type)
+end
+
+local function buildSuper(class, tp)
+ if not tp.supertypes then
+ return ''
+ end
+ local parents = {}
+ for _, parent in ipairs(tp.supertypes) do
+ parents[#parents+1] = ('%s.%s'):format(class, parent)
+ end
+ return (': %s'):format(table.concat(parents, ', '))
+end
+
+local function buildFunction(class, func, node)
+ local text = {}
+ text[#text+1] = '---'
+ text[#text+1] = ('---%s'):format(func.description:gsub('([\r\n])', '%1---'))
+ text[#text+1] = '---'
+ local params = {}
+ for _, param in ipairs(func.variants[1].arguments or {}) do
+ params[#params+1] = param.name
+ text[#text+1] = ('---@param %s %s # %s'):format(
+ param.name,
+ buildType(class, param),
+ param.description
+ )
+ end
+ for _, rtn in ipairs(func.variants[1].returns or {}) do
+ text[#text+1] = ('---@return %s %s # %s'):format(
+ buildType(class, rtn),
+ rtn.name,
+ rtn.description
+ )
+ end
+ text[#text+1] = ('function %s%s(%s) end'):format(
+ node,
+ func.name,
+ table.concat(params, ', ')
+ )
+ return table.concat(text, '\n')
end
local function buildFile(class, defs)
@@ -23,30 +85,17 @@ local function buildFile(class, defs)
for _, func in ipairs(defs.functions or {}) do
text[#text+1] = ''
- text[#text+1] = '---'
- text[#text+1] = ('---%s'):format(func.description:gsub('([\r\n])', '%1---'))
- text[#text+1] = '---'
- local params = {}
- for _, param in ipairs(func.variants[1].arguments or {}) do
- params[#params+1] = param.name
- text[#text+1] = ('---@param %s %s # %s'):format(
- param.name,
- buildType(param),
- param.description
- )
- end
- for _, rtn in ipairs(func.variants[1].returns or {}) do
- text[#text+1] = ('---@return %s %s # %s'):format(
- buildType(rtn),
- rtn.name,
- rtn.description
- )
+ text[#text+1] = buildFunction(class, func, class .. '.')
+ end
+
+ for _, tp in ipairs(defs.types or {}) do
+ text[#text+1] = ''
+ text[#text+1] = ('---@class %s%s'):format(getTypeName(class, tp.name), buildSuper(class, tp))
+ text[#text+1] = ('local %s = {}'):format(tp.name)
+ for _, func in ipairs(tp.functions or {}) do
+ text[#text+1] = ''
+ text[#text+1] = buildFunction(class, func, tp.name .. ':')
end
- text[#text+1] = ('function %s.%s(%s) end'):format(
- class,
- func.name,
- table.concat(params, ', ')
- )
end
text[#text+1] = ''