Version 0.3.2
LÖVE Documentation
OverviewLicenseCreditsInstallingGetting started
Devices
love.graphicslove.audiolove.keyboardlove.mouselove.filesystemlove.timerlove.system
Types
AnimationColorFontFileImageMusicParticleSystemSound
Callbacks
loadupdatedrawmousepressedmousereleasedkeypressedkeyreleased
Miscellaneous
ConstantsConfig filesKeyboard shortcuts
Function
love.graphics.line( x1, y1, x2, y2 )
Usage
love.graphics.line( x1, y1, x2, y2 )
Arguments
x1First x-coordinate.
y1First y-coordinate.
x2Second x-coordinate.
y2Second y-coordinate.
Returns
Nothing
Examples
Example 1: Draw a horizontal and a slanted line. love.graphics.line(100,100, 300,100) -- horizontal
love.graphics.line(100,100, 300,300) -- diagonal