Grass
Grass is entirely optional, but can be customized via map parameters and adds a nice touch to your map.
 |
|
| Example Grass Disribution
|
In Game Result
|
Specification
mapinfo.lua
local mapinfo = {
...
resources = {
...
grassBladeTex = "",
grassShadingTex = "",
...
},
...
grass = {
bladeWaveScale = 1.0,
bladeWidth = 0.32,
bladeHeight = 4.0,
bladeAngle = 1.57,
bladeColor = {0.59, 0.81, 0.57},
},
...
}
Blade Wave Scale
Defaults to 1. It specifies how much the blades will wave in the wind. Higher makes them wave more.
Blade Height
Blade Angle
Blade Color
does nothing when blade texture is set.
Distribution Image
Formerly Feature Map. Grass distribution is defined by blue pixels, the more blue the pixel is (the closer to blue 255 it is), the thicker grass will be at that location.
| File Location
|
The distribution map is an intermediary file compiled into the SMF/SMT files using MapConv or MapConvNG.
|
| File Format
|
Any that Mapconv programs support
|
| Colour Depth
|
8bpp
|
| Channels
|
RGB
|
| Resolution
|
| Spring Map Size*
|
pixels = Spring Map Size * 64
|
| 2
|
128
|
| 4
|
256
|
| 6
|
284
|
| ...
|
...
|
| 32
|
2048
|
| * must be multiples of 2
|
|
Shading Image
- If a shading image is not present, the minimap will be used in its place.
| File Location
|
./maps/
|
| File Format
|
PNG, TGA
|
| Colour Depth
|
8bpp
|
| Channels
|
RGB
|
| Resolution
|
Any, recommended powers of two, will be stretched over the terrain.
|
| FIXME: |
FIXME:
|
| Example |
Result
|
Blade Texture
FIXME: need more info.
| File Location
|
./maps/
|
| File Format
|
PNG, TGA
|
| Colour Depth
|
8bpp
|
| Channels
|
RGB
|
| Resolution
|
FIXME:
|
| FIXME: |
FIXME:
|
| Example |
Result
|
Forum Discussions