Intellij idea autocomplete


I am a big fun of intellij idea. So i integrate defold api with it.

To use Idea with lua and defold your need.
1)Install lua plugin. EmmyLua
2)Edit file associations. Press ctrl + shift + a. Then enter command Edit file associations. To lua language add .*script .*render_script .*gui_script.
3)Download defold api library.
I create a tool that parse defold docs and generate lua files with description.
You need download zip file from
4)Add library to your project.
File/Project structure/libraries/lua zip library.
5)Use it =)


This is AWESOME!!! Thank you!


Thanks you! Fantastic work!


Emmylua is a very nice lua extension to idea and I use it with defold for a long time.


And how to run and debug project from IDEA?


No way. We need write plugin for that.


@d954mas is there any way to set defold editor automatically reload file if it was changed in another program like idea does?


i write scripts, only in idea. Then run game from defold editor. I don’t edit script from defold and from IDEA in same time. If editor not automaticaly reload file, you should make issue for that.


is it possible to use this in zerobrane ?


Is there any way to add a warning about using global variables in IDEA? The only thing that I found about it is this issue but it’s in Chinese and according to google translate EmmyLua doesn’t support it for now :frowning:


It has luacheck support. Rightclick your code and hit use luacheck. Itll open a prompt and ask you to point towards the luacheck exe


Actually you can even set it as an option. Hit ctrl + alt + s, go to editor/inspections/lua “global name can be local”


This one is just what I’ve looked for, thanks!


How do i remove the upvalue underlining? its really distracting

edit: of course i ended up finding it right after asking (its under syntax highlighting)


1)fixed return value in api headers

 ---Creates a new zero vector with all components set to 0.
- ---@return v vector3 new zero vector
+ ---@return  vector3 new zero vector
 function vmath.vector3() end

2)add headers for vector3/vector4

3)update api to version 1.2.129


1)fix gui autocompile(replace - to _)

---@param line-break boolean true or false
function gui.set_line_break(node, line-break) end

2)fix luasocket autocompile ("*" as name)

---@param "*" string if address is "*"" and the object is connected, the peer association is removed and 
function connected:setpeername("*") end

3)Add timer autocomplite.(i add it by myself. Please add timer doc to docs @sven )
4)make class global. Idea will now autocomplite sprite, spine and etc. Before it autocomplite only their functions
5)Add jar and instruction to generate headers @AGulev


1)update api to version 1.2.136
2)timer api from from timer_doc.json

No more than 3 consecutive replies are allowed. Please edit your previous reply instead, or wait for someone to reply to you. LOL=) So update prev post.

1)update api to version 1.2.143
2)autocomplete returned tables(sys.get_sys_info() … )
3)autocomplete url fields(socket, path, fragment)
4)Add this project to asset page.