Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Looking for DFHack IDE / setup for LUA development.  (Read 1382 times)

Discipol

  • Bay Watcher
    • View Profile
Looking for DFHack IDE / setup for LUA development.
« on: February 10, 2014, 05:47:28 pm »

So I got an Eclipse with a LUA plugin. Its not more than a compile and color syntax editor but I am looking for more.

Code: [Select]
local unit = dfhack.gui.getSelectedUnit();
This gets me the unit under the cursor, or NIL.
I would like to have the ctrl+space / autocomplete functionality that Eclipse is capable of, for code speed, avoiding typos and exploring the workings of the system.

I have no idea if what I need already exists, the relative anonymity of DFHack and DF itself does not help my google searches.

Thus I am to rely on you gents for assistance.

Cheerio!
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #1 on: February 10, 2014, 07:24:36 pm »

I use notepad++ with its autocomplete and lua highlighting features.

I'm not entirely sure what you're asking for.
« Last Edit: February 10, 2014, 07:28:18 pm by Putnam »
Logged

Discipol

  • Bay Watcher
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #2 on: February 11, 2014, 02:29:06 am »

I am interested in autocompleting Dwarf Fortress stuff. Like you would type dfhack. then the autocomplete would have, among other suggestions, "gui" and gui would show, among other methods, "getSelectedUnit".

Any way to bring this up?
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #3 on: February 11, 2014, 10:33:21 am »

That would have to be made.

It does sound doable, though, at least sorta.

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #4 on: February 11, 2014, 03:04:33 pm »

Getting autocomplete for function names would presumably just be a matter of pointing the IDE at DFHack's Lua script folder.

Getting autocomplete for structure fields, on the other hand, would probably be nontrivial since those are compiled into DFHack itself rather than read at runtime (as the Ruby plugin does).

Also, Lua is not an acronym - it's capitalized as "Lua", not "LUA".
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

Discipol

  • Bay Watcher
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #5 on: February 11, 2014, 03:55:34 pm »

Getting autocomplete for function names would presumably just be a matter of pointing the IDE at DFHack's Lua script folder.

Getting autocomplete for structure fields, on the other hand, would probably be nontrivial since those are compiled into DFHack itself rather than read at runtime (as the Ruby plugin does).

Also, Lua is not an acronym - it's capitalized as "Lua", not "LUA".

So Q, are you suggesting I switch to Ruby? Am as beginner at Lua as I am at Ruby.
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #6 on: February 11, 2014, 04:08:17 pm »

No, he's saying that it would be somewhat difficult to do all this autocomplete.

I do it by looking it up, whether through the lua interface, gui/gm-editor or the df-structures github.

Discipol

  • Bay Watcher
    • View Profile
Re: Looking for DFHack IDE / setup for LUA development.
« Reply #7 on: February 11, 2014, 04:09:45 pm »

bah, I guess it takes a bit of time to learn the most used thingies, I guess. ty for the info dudes
Logged