Thread Tools Display Modes
04/10/14, 11:45 PM   #1
Tinuviel
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 7
IntelliJ and sylvanaar

Hi there,

As I am a professional developer that works in Visual Studio all day, I guess I'm a bit spoiled by IDE's with a good feature set. Specifically, I missed syntax checking and code completion (intellisense). Because of this, I looked around for a bit and finally found a very good solution. It adds both missing features - and after configuration - full API intellisense. As such, I figured I would share my findings with other developers.





IDE: IntelliJ Community Edition. You can find it here: http://www.jetbrains.com/idea/download/

After IntelliJ is installed, you then need to add LUA support, and luckly someone already made a plugin for this! To install it, open IntelliJ and go to File->Settings->Plugins, click on 'Browse Repositories', search for 'Lua', and click 'Install'. If you want more information about the plugin itself, you can find it here: https://bitbucket.org/sylvanaar2/lua-for-idea/wiki/Home.

Now all that is needed is to add the ESO API into the intellisense. This requires a set of .lua files that define the functions and constants. There was nothing out there I could find in this format, so I created them myself! Simply extract this zip out to a folder and you're ready for the next step:
https://www.dropbox.com/s/4gbmmerpes...lls-online.zip.

These lua files were generated with a set of powershell scripts I created. With those, I copy/paste the api information off the esoui wiki pages into a text document, save the document, then run the powershell scripts. For those interested in those scripts, please PM me.

To enable to API intellisense:
Create a new project, select 'Lua' as your framework, press 'configure', choose 'LuaJ' then press the '+' button on the right. In the dialog that pops up, select the folder you extracted earlier.

Now when you make new projects just select the 'LuaJ' target, and you will have intellisense for the ESO API and your own code!

Last edited by Tinuviel : 04/11/14 at 12:41 PM. Reason: I was super tired when I wrote this, so I just cleaned up a lot of grammar.
  Reply With Quote
04/11/14, 12:13 PM   #2
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 648
Corrected your typo in the title (in sylv's name).

I remember when he made that for WoW...
  Reply With Quote
04/11/14, 10:46 PM   #3
SpecialK
Join Date: Apr 2014
Posts: 6
Well take a look at "Havok Script":
http://www.havok.com/products/script

It's what the game uses.
As you can see it has an IDE with intelliSense, etc.

One could probably get a basic license, maybe an "indie" license, or something for cheap.
  Reply With Quote
04/15/14, 12:29 PM   #4
Iyanga
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 183
Does the syntax checker from IntelliJ just mark lexical errors or grammatical errors, too?

In example, will it tell you that this code is not valid LUA:

if a == false then
local bla = a
else if b == false then
local bla = b
end


(Just wondering if it's worth to switch the IDE, but don't want less features.)
  Reply With Quote
04/15/14, 05:04 PM   #5
Tinuviel
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 7
Originally Posted by Iyanga View Post
Does the syntax checker from IntelliJ just mark lexical errors or grammatical errors, too?

In example, will it tell you that this code is not valid LUA:

if a == false then
local bla = a
else if b == false then
local bla = b
end


(Just wondering if it's worth to switch the IDE, but don't want less features.)
Just looked, and it doesn't.
  Reply With Quote
04/15/14, 05:13 PM   #6
Tyx
 
Tyx's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 23
Thank you for you hard work - is it possible to implement your script in Eclipse too?

I prefer to work with Eclipse because IntelliJ is to slow on my system, and Eclipse offers the usual great debug and work interface (at least in my eyes maybe just used to it)
  Reply With Quote
04/20/14, 03:18 AM   #7
geri
Join Date: Apr 2014
Posts: 1
Thanks Tinuviel, thats helpful!


@Iyanga: What IDE do you use?
  Reply With Quote
04/21/14, 09:35 PM   #8
Wykkyd
Are you Wykkyd Gaming?
 
Wykkyd's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 107
I work all day in Visual Studio.

I should probably use an IDE for Lua too, eh? I've done everything up to this point in Notepad++.
  Reply With Quote
04/21/14, 09:52 PM   #9
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 648
<3 Notepad++
  Reply With Quote
04/22/14, 12:03 AM   #10
stjobe
 
stjobe's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 60
Originally Posted by Wykkyd View Post
I work all day in Visual Studio.

I should probably use an IDE for Lua too, eh? I've done everything up to this point in Notepad++.
Originally Posted by Seerah View Post
<3 Notepad++
Notepad++

IntelliJ + ESO Lua looks interesting though, might have to use it for the next project. Thanks for the tip
  Reply With Quote
04/22/14, 01:30 PM   #11
ins
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 76
Nobody use good old Notepad anymore?

Gonna test this with VS. Hopefully it works in 2010.
  Reply With Quote
04/28/14, 08:54 AM   #12
lyravega
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 93
Originally Posted by Wykkyd View Post
...I've done everything up to this point in Notepad++.
Npp
Best thing ever.
  Reply With Quote
04/28/14, 10:04 AM   #13
Stormknight
 
Stormknight's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 128
Nice find! Whilst Notepad++ is pretty good, I've been using Ultra Edit for around 15 years.
  Reply With Quote
04/28/14, 10:47 AM   #14
ins
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 76
Originally Posted by Stormknight View Post
Nice find! Whilst Notepad++ is pretty good, I've been using Ultra Edit for around 15 years.
Uedit32 is great

And fast... Its great to use it to when you want to edit HUUUUUUUUUUUGE files since it handles those quite nicely
  Reply With Quote
05/05/14, 04:33 AM   #15
DerVagabund
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 12
Originally Posted by Wykkyd View Post
I work all day in Visual Studio.

I should probably use an IDE for Lua too, eh? I've done everything up to this point in Notepad++.
Heh, and I thought I am the only one doing this

I think I will stay with Notepad++ as I do not need to compile LUA before running it, thus I see no real need for a development environment. Sure it would be nice to have auto completion suggestions for code but unless all the ESO internal functions are supported I see no real need, as lua itself is not that much different to all other programming languages
  Reply With Quote
05/05/14, 04:51 AM   #16
Harven
 
Harven's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 135
Hey,
the code copletion feature in IntelliJ looks great. I'm using LuaEdit but I don't know if it's possible to add the eso api to thier code copletion mechanism.
  Reply With Quote
05/10/14, 10:07 PM   #17
Marihk
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 5
Thumbs up Thanks

Thanks very much for providing this. It's been most helpful!
  Reply With Quote
05/11/14, 02:31 AM   #18
CatoTheElder
Join Date: May 2014
Posts: 44
vi

Tried, trusted, and true... I find the compiler does a pretty damned good job of showing errors.
  Reply With Quote
05/11/14, 12:46 PM   #19
katkat42
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 155
Originally Posted by CatoTheElder View Post
vi

Tried, trusted, and true... I find the compiler does a pretty damned good job of showing errors.
Personally, I'm waiting for someone to write an EMACS major mode...
  Reply With Quote
05/11/14, 02:15 PM   #20
Feroc
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 5
Thanks for the info. I am working in VS the whole day, too. Right now I am only using Notepad++ for my small addons, but I guess I could start to organize them a bit better and a better IDE would be helpful for that.
  Reply With Quote

ESOUI » Developer Discussions » Dev Tools » IntelliJ and sylvanaar

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off