So...
I seem to remember in earlier versions of Spring there being a LUA option in the main gui. Alas, I cannot find this option in the current version. Is this intentional?
Also, may have been mentioned before, but a command line argument for scripts would be nice. Could lead to use-map-settings ala Starcraft style play in the future.
Anyways... hope to gain some insight into this
LUA scripting?
Moderator: Moderators
Sorry to be a bit out of subject, but
I was brainstorming about making a software to make "use map setting" without knowing LUA. ( With some sort of "Trigger","Condition","Action")
It's not easy to make someting usefull and easy to use...
If a lot of people would be interessed, I could look at it a bit deeper.
I was brainstorming about making a software to make "use map setting" without knowing LUA. ( With some sort of "Trigger","Condition","Action")
It's not easy to make someting usefull and easy to use...
If a lot of people would be interessed, I could look at it a bit deeper.
Well, essentially, the functionality of LUA already exists. With not too much effort and editor or translator/compiler could be made to translate a Starcraft style language into LUA ( or other complex language). It would be as simple as providing a basic framework class, then plug in events, listeners, etc... Of course, it would be more efficient to build it straight into Spring.
However, I think the option of a language such as LUA is important as it makes some tasks easier (such as variable manipulation and math).
However, I think the option of a language such as LUA is important as it makes some tasks easier (such as variable manipulation and math).
In a perfectly modularized and documented engine, yes, it would be relatively simple to add LUA.
The problem is the non-good (read: semi-sloppy) structure of bits of the Spring engine that make this a pain in the ass; a full and "proper" restructuring (i believe Tobi suggests laid this out more fully on the mailing list) would be the best way to go, but its a ways away yet.
Yeah, there's lot of cool stuff that can happen with full LUA implementation; its not hard to imagine fully scriptable unit OOP-ified unit scripts and map features and campaigns and procedural content bits that could be generated to make campaigns
But its goign to take some time matey... i think Fnordia (who is terribly 1337) is the main programmer tackling the problem right now...
The problem is the non-good (read: semi-sloppy) structure of bits of the Spring engine that make this a pain in the ass; a full and "proper" restructuring (i believe Tobi suggests laid this out more fully on the mailing list) would be the best way to go, but its a ways away yet.
Yeah, there's lot of cool stuff that can happen with full LUA implementation; its not hard to imagine fully scriptable unit OOP-ified unit scripts and map features and campaigns and procedural content bits that could be generated to make campaigns

But its goign to take some time matey... i think Fnordia (who is terribly 1337) is the main programmer tackling the problem right now...
Lua support is indeed planned, and I'm almost sure it will make to the engine. The actual problem is when.
Like D45 said, it's a pain to do right now. Also there are another stuff to be solved, like the full multiplatform support, along with other things that are part of the Spring 1.0 Roadmap plan.
Lua is pretty much into the 2.0 Roadmap, along with the "perfectly modularized and documented engine" plans.
Like D45 said, it's a pain to do right now. Also there are another stuff to be solved, like the full multiplatform support, along with other things that are part of the Spring 1.0 Roadmap plan.
Lua is pretty much into the 2.0 Roadmap, along with the "perfectly modularized and documented engine" plans.
- Drone_Fragger
- Posts: 1341
- Joined: 04 Dec 2005, 15:49
Go and make LUA scripts for garries mod. There needs to be more LUA scriptors making good game types. :D
http://gmod.garry.tv/
And yes, LUA in Spring wouild be nice, Becuase SupCom would use LUA as well. Whole Sup Com gamesmodes done before the Release date FTW ^-^
http://gmod.garry.tv/
And yes, LUA in Spring wouild be nice, Becuase SupCom would use LUA as well. Whole Sup Com gamesmodes done before the Release date FTW ^-^
- Drone_Fragger
- Posts: 1341
- Joined: 04 Dec 2005, 15:49
Hey guys, I'm not exactly advocating adding new LUA bindings right now, just wondering what happened to the ones that used to be.
Quoth the changelog circa v0.65b1:
"-Added bindings for creating startscripts in lua. See testscript.lua for an example. Note that you can only have one script (must be called testscript.lua), and that it is possible that the interface will change."
And shortly, in v0.65b2:
"-Added support for having more than one lua startscript. Put them in subfolder "startscripts"."
I also distinctly remember playing with LUA testmission.lua in my earlier moments with Spring.
Now, maybe I am mistaken, but I see nothing about removing the bindings in the changelog. I sense a conspiracy afoot....
Quoth the changelog circa v0.65b1:
"-Added bindings for creating startscripts in lua. See testscript.lua for an example. Note that you can only have one script (must be called testscript.lua), and that it is possible that the interface will change."
And shortly, in v0.65b2:
"-Added support for having more than one lua startscript. Put them in subfolder "startscripts"."
I also distinctly remember playing with LUA testmission.lua in my earlier moments with Spring.
Now, maybe I am mistaken, but I see nothing about removing the bindings in the changelog. I sense a conspiracy afoot....
Again, due to semi-sloppy engine structure (Not dissing the SYs, but its true...), what is present is a highly specialized LUA implmentation; this isnt a "generalized' solution.
This is exclusively a map/mission start-script generator that you can tool with in LUA. Meaning that you can use LUA to say "start with so many units on position X if difficulty is hard" and other similarly basic things.
It was made to mostly accomdate some peopel who said they wanted a little more flexible start-script structure (before it was just CSV iirc) for units to start with.
I also think Fnord used it to gain some experience with Lua with.
This is exclusively a map/mission start-script generator that you can tool with in LUA. Meaning that you can use LUA to say "start with so many units on position X if difficulty is hard" and other similarly basic things.
It was made to mostly accomdate some peopel who said they wanted a little more flexible start-script structure (before it was just CSV iirc) for units to start with.
I also think Fnord used it to gain some experience with Lua with.
