Maybe a simple question:
Water colour is defined in map.smd as WaterBaseColor= r g b;. Is it possible to read those values into a gadget in a mod, and if so how? Is there a similar callin as getModInfo for maps that maybe works?
Get watercolour from map
Moderator: Moderators
Re: Get watercolour from map
http://springrts.com/wiki/Mapdev:mapinfo.lua
Check if mapinfo.water.planeColor != null to see if old smd map configs are also available in lua.
Check if mapinfo.water.planeColor != null to see if old smd map configs are also available in lua.
Re: Get watercolour from map
Yes, that's what I want. Only, for me the mapinfo variable was nil, and I could not get it with getModInfo or getMapInfo.
But I found that you can get it from engine like this:
color Game.waterBaseColor as table(r,g b)
But I found that you can get it from engine like this:
color Game.waterBaseColor as table(r,g b)
Re: Get watercolour from map
Would have been nice if it had worked in the same way instead of two separate paths. Future improvement fit for a student project?..