URL: http://bugs.freeciv.org/Ticket/Display.html?id=39387
Re-reading the original posting, that should be match_style.
After much testing, I've completely eliminated match_style, and its
parameters none, bool, and full.
Instead, I've replaced it with match_with, a listing of match_types.
This allows completely orthogonal operations between styles. Styles
are determined automagically (internally).
That is,
layer0_match_style = bool
layer0_match_type = hills
becomes
layer0_match_type = hills
layer0_match_with = hills
Simple enough. The elegance comes as more match_with types are added:
layer0_match_type = shallow
layer0_match_with = land, deep
The above is the equivalent of the old match_style = full, but doesn't
interfere with other tiles' matching styles. *And* may be extensible to
more than 3 types! (Currently limited to 3 as before.)
This patch doesn't make any substantive changes. It continues to operate
in exactly the same manner as before, so that old savegames will run
without modification.
Never-the-less, this is the big one! Old tilesets will no longer work.
(Replacements are provided for the main 5 here.)
I've tested 2.1 savegames against all 5 tilesets, and also trunk edit
savegames (with deep water) against all 5 tilesets.
Index: data/trident.tilespec
===
--- data/trident.tilespec (revision 13103)
+++ data/trident.tilespec (working copy)
@@ -2,7 +2,7 @@
[tilespec]
; Format and options of this tilespec file:
-options = +tilespec4.2007.Feb.20
+options = +tilespec4.2007.Jul.13
; A simple name for the tileset specified by this file:
name = Trident
@@ -86,169 +86,138 @@
; Terrain info - see README.graphics
[layer0]
-match_style = BOOL
match_types = arctic, desert, forest, grassland, hills, jungle,
mountains, water, plains, swamp, tundra
[layer1]
-match_style = BOOL
match_types = water
[layer2]
-match_style = BOOL
match_types = water
; Water graphics referenced by terrain.ruleset
;
-[terrain_coast]
+[tile_coast]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
-[terrain_shelf]
+[tile_shelf]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
-[terrain_floor]
+[tile_floor]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
-[terrain_trench]
+[tile_trench]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
-[terrain_ridge]
+[tile_ridge]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
-[terrain_vent]
+[tile_vent]
is_blended = 0
num_layers = 3
-layer0_match_style = none
layer0_match_type = water
-layer1_match_style = bool
layer1_match_type = water
-layer2_match_style = bool
+layer1_match_with = water
layer2_match_type = water
-layer2_cell_type = rect
+layer2_match_with = water
+layer2_sprite_type = corner
; Land graphics referenced by terrain.ruleset
;
-[terrain_arctic]
+[tile_arctic]
is_blended = 0
num_layers = 1
-layer0_match_style = bool
layer0_match_type = arctic
+layer0_match_with = arctic
mine_sprite = tx.oil_mine
-[terrain_desert]
+[tile_desert]
is_blended = 0
num_layers = 1
-layer0_match_style = bool
layer0_match_type = desert
+layer0_match_with = desert
mine_sprite = tx.oil_mine
-[terrain_forest]
+[tile_forest]
is_blended = 0
num_layers = 1
-layer0_match_style = bool
layer0_match_type = forest
+layer0_match_with = forest
-[terrain_grassland]
+[tile_grassland]
is_blended = 0
num_layers = 1
-layer0_match_style = bool
layer0_match_type = grassland
+layer0_match_with = grassland
-[terrain_hills]
+[tile_hills]
is_blended = 0
num_layers = 1
-layer0_match_style = bool
layer0_match_type = hills
+layer0_match_with = hills
mine_sprite = tx.mine
-[terrain_jungle]
+[tile_jungle]