ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Dev Tools (https://www.esoui.com/forums/forumdisplay.php?f=173)
-   -   IntelliJ and sylvanaar (https://www.esoui.com/forums/showthread.php?t=776)

Tinuviel 04/10/14 11:45 PM

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!

Seerah 04/11/14 12:13 PM

Corrected your typo in the title (in sylv's name). ;)

I remember when he made that for WoW...

SpecialK 04/11/14 10:46 PM

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.

Iyanga 04/15/14 12:29 PM

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.)

Tinuviel 04/15/14 05:04 PM

Quote:

Originally Posted by Iyanga (Post 4483)
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.

Tyx 04/15/14 05:13 PM

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)

geri 04/20/14 03:18 AM

Thanks Tinuviel, thats helpful!


@Iyanga: What IDE do you use?

Wykkyd 04/21/14 09:35 PM

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++.

Seerah 04/21/14 09:52 PM

<3 Notepad++

stjobe 04/22/14 12:03 AM

Quote:

Originally Posted by Wykkyd (Post 5275)
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++.

Quote:

Originally Posted by Seerah (Post 5279)
<3 Notepad++

Notepad++

IntelliJ + ESO Lua looks interesting though, might have to use it for the next project. Thanks for the tip :)

ins 04/22/14 01:30 PM

Nobody use good old Notepad anymore? :)

Gonna test this with VS. Hopefully it works in 2010.

Tinuviel 04/25/14 07:35 PM

I work in Visual Studio all day as well. I'm a professional .NET developer for trade.
This was just the easiest way to get features I'm used to. Honestly, I've been spoiled rotten by VS2013 and Resharper. (even though I have VS installed at home, I wasn't in the mood to figure out how to set this up)

I use Notepad++ all the time too, but generally for lighter things. A lot of the time it's for manual .csproj / .vbproj editing, one-off quick fixes, viewing XML / nuspec / build logs, etc. When I'm making something more meaty, I like more help.

Tinuviel 04/25/14 07:38 PM

Quote:

Originally Posted by Tyx (Post 4532)
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)

I found this by looking at WoW solutions and altering them to fit ESO. I would search for that, and look into modifying it to work with Eclipse. I did see some Eclipse plugin somewhere, but I have used Eclypse in the past and there are a bunch of small differences between the Visual Studio methodology that have always irritated me, so I didn't pursue that route.

lyravega 04/28/14 08:54 AM

Quote:

Originally Posted by Wykkyd (Post 5275)
...I've done everything up to this point in Notepad++.

Npp
Best thing ever.

Stormknight 04/28/14 10:04 AM

Nice find! Whilst Notepad++ is pretty good, I've been using Ultra Edit for around 15 years. ;)

ins 04/28/14 10:47 AM

Quote:

Originally Posted by Stormknight (Post 6236)
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 :)

Wobin 04/28/14 12:05 PM

Quote:

Originally Posted by ins (Post 6242)
Uedit32 is great :)

And fast... Its great to use it to when you want to edit HUUUUUUUUUUUGE files since it handles those quite nicely :)

I've just used gvim for ridiculously large files.

Tyx 05/02/14 06:39 AM

Quote:

Originally Posted by Tinuviel (Post 5915)
I found this by looking at WoW solutions and altering them to fit ESO. I would search for that, and look into modifying it to work with Eclipse. I did see some Eclipse plugin somewhere, but I have used Eclypse in the past and there are a bunch of small differences between the Visual Studio methodology that have always irritated me, so I didn't pursue that route.

I know what you mean. I tried Visual Studio once when I had to work with c++ but it felt somewhat off. So same thing but the other way ;)

Thanks for the tip.

DerVagabund 05/05/14 04:33 AM

Quote:

Originally Posted by Wykkyd (Post 5275)
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 :D

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 :)

Harven 05/05/14 04:51 AM

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.


All times are GMT -6. The time now is 08:57 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI