LOVELY2D
LOVE2D API support for Sublime Text 4
Details
Installs
- Total 1K
- Win 854
- Mac 141
- Linux 294
Nov 21 | Nov 20 | Nov 19 | Nov 18 | Nov 17 | Nov 16 | Nov 15 | Nov 14 | Nov 13 | Nov 12 | Nov 11 | Nov 10 | Nov 9 | Nov 8 | Nov 7 | Nov 6 | Nov 5 | Nov 4 | Nov 3 | Nov 2 | Nov 1 | Oct 31 | Oct 30 | Oct 29 | Oct 28 | Oct 27 | Oct 26 | Oct 25 | Oct 24 | Oct 23 | Oct 22 | Oct 21 | Oct 20 | Oct 19 | Oct 18 | Oct 17 | Oct 16 | Oct 15 | Oct 14 | Oct 13 | Oct 12 | Oct 11 | Oct 10 | Oct 9 | Oct 8 | Oct 7 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 0 | 2 | 0 | 0 | 0 | 0 | 2 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 1 | 3 | 0 | 0 | 1 | 1 | 0 | 0 | 2 | 0 | 0 | 0 | 1 | 1 | 0 | 1 | 0 | 1 | 1 | 3 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 1 | 2 | 0 | 1 |
Mac | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 |
Linux | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 |
Readme
- Source
- raw.githubusercontent.com
LÖVELY2D
A (WIP) Sublime Text 4 plugin for LÖVE2D development that provides autocomplete and API information.
Based on LÖVE-API.
Status: LSP-lua now ships with LÖVE2D support. Unless you want to avoid LSP, I recommend that over LÖVELY2D.
Installation
Package Control
LÖVELY2D is available on Package Control.
Manually
- Navigate to your
Packages
folder (easiest way to find it is from within Sublime Text, go toPreferences > Browse Packages...
). - Download the latest release from the releases page.
- Unzip the downloaded archive. Copy the directory
LOVELY2D-x.x.x
into yourPackages
folder.
With Git
Use git clone
to clone this repository into your Packages
folder.
# From within your `Packages` folder
git clone https://github.com/kevinfiol/LOVELY2D.git
Usage
From within a .lua
file, set the syntax to LOVELY2D
. Autocomplete and hover tips should function normally.
Tip: I recommend setting "auto_complete_preserve_order": "none"
in your Sublime preferences for more predictable auto-complete behavior.
Usage with Sublime LSP
Sublime LSP is an implementation of the Language Server Protocol for Sublime Text.
Note: the LSP-lua package now ships with LÖVE2D support out of the box that is more intelligent than LOVELY2D thanks to the Language Server Protocol. You may or may not want to use LOVELY2D in conjunction with Sublime LSP for this reason. Nevertheless, see below if you'd like to continue:
- Install Sublime LSP.
- Install LSP-lua
- Open the Command Palette, and go to
LSP-lua Settings
. Modify theselector
andLua.diagnostics.globals
property so that LÖVELY2D Syntax files are correctly parsed and diagnostics doesn't nag you about thelove
global. Example:
{
"selector": "source.lovely | source.lua",
"settings": { "Lua.diagnostics.globals": ["love"] }
}
Known Issues / To-Do
- (Bug) Invoking the API popup on anything under the
love.
namespace closes the autocomplete. This is unintended, and I'm not sure why it happens (help appreciated!) - Function override signatures not provided in hints
- Hover tips are sometimes overridden by Reference tips
- General clean-up / commenting
Implement function signature helper while typing in parameters(Added in 0.6.0)