Lua map config files + MapOptions.lua

Lua map config files + MapOptions.lua

Discuss maps & map creation - from concept to execution to the ever elusive release.

Moderator: Moderators

Post Reply
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Lua map config files + MapOptions.lua

Post by trepan »

I've just committed the TDF -> LUA change for maps
to SVN. This will allow mappers more "game-time"
control of their map configuration (although there is
still a little work to be done for the SM3 format). Any
parameter in the SMD file can be setup with the help
of the MapOptions.lua file before a game starts. Some
things you can do with this feature:

- adjustable metal density / extraction radius
- adjustable tidal strength
- adjustable wind (min and max)
- adjustable gravity
- rendering themes
  • - lighting tints
    - fog adjustments
    - cloud density
    - water color (and texture changes, esp for the new BumpWater)
    - skyBox texture
- terrain type speed changes (tank, kbot, etc...)
- map deformation (allow? hardness)

Once the SM3 format is fully converted, you'll also be
able to change its texture usage via MapOptions.lua.

The MapOptions.lua file can also access the map's config script
file to pull out the map defaults. This makes it so that you can
have a generic MapOptions.lua and map parser file set that you
can add to any map archive to make it "game-time" configurable.
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: Lua map config files + MapOptions.lua

Post by Forboding Angel »

Does this mean that you are working on unforking sm3? Cause if so.......

WIN!!!

TBH, I really cba to do smt mapping anymore. If I didn't have evolution to worry about then maybe I would start doing it again, but SM3 is the logical choice for many obvious reasons.
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Re: Lua map config files + MapOptions.lua

Post by trepan »

No, it does not mean that I'm doing any work on
SM3 other than changing it's configuration setup.
There was nothing in my post to indicate
otherwise. To be honest, I'll probably leave that
as the last TDF->lua conversion (seeing as it's
basically not being used).

Add a decent feature, and all I get for my efforts
is a feature request post (essentially off-topic
given the limited scope of my topic). So be it.
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: Lua map config files + MapOptions.lua

Post by Forboding Angel »

huh?

I was just hoping. No need to get upset. And the feature is appreciated, because someday SM3 will actually be possible to use and this will be needed (worldbuilder anyone).

Sorry for that.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Lua map config files + MapOptions.lua

Post by smoth »

I read your post and was most excited about it but i am too over-extended to currently utilize it trepan. That does not mean that I did not read the post and think of future applications including weather and day/night. I really thought that it is spiffy.
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Re: Lua map config files + MapOptions.lua

Post by trepan »

I plan to add a MapOptions.lua / map_config.lua set to the
base maphelper.sdz archive that will let you use this feature
by simply adding "useMapOptions = true" to your map config
file (whether it be SMD or SM3, format varying based on TDF or
LUA file type). I'll add the basics in there (grav, wind, tidal, metal,
etc...), and some lighting junk. Might get a preliminary version
in today.
User avatar
SirArtturi
Posts: 1164
Joined: 23 Jan 2008, 18:29

Re: Lua map config files + MapOptions.lua

Post by SirArtturi »

Great !

I was about to do some mapoption.lua's for my new map but seems that maybe theres no need... :>
User avatar
hunterw
Posts: 1838
Joined: 14 May 2006, 12:22

Re: Lua map config files + MapOptions.lua

Post by hunterw »

oh man the lighting junk would really help
User avatar
Beherith
Posts: 5145
Joined: 26 Oct 2007, 16:21

Re: Lua map config files + MapOptions.lua

Post by Beherith »

Trepan, could you please post an example script to this or point me to some form of documentation? I am immensly interested in this, and would like to make some form of showcase by the time .77 gets released :)
Post Reply

Return to “Map Creation”