mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-07 21:35:37 +00:00
move some macros from util.cfg to compat.cfg...
...since we have better way to do that now. They are unused in mainline
This commit is contained in:
parent
74e5f6360b
commit
b631191992
@ -1 +1,66 @@
|
||||
#textdomain wesnoth
|
||||
|
||||
#Backward compatibility file, these are not used in mainline, and an upgrade path through wmllint should be a good idea
|
||||
# added in the 1.9 timeframe
|
||||
|
||||
#define VIMG BASE_STRING NAME_STRING
|
||||
[image]
|
||||
name={NAME_STRING}
|
||||
base={BASE_STRING}
|
||||
[/image]
|
||||
#enddef
|
||||
|
||||
#define TERRAIN_BASE_DEFAULT IMAGESTEM
|
||||
[terrain_graphics]
|
||||
[tile]
|
||||
x=0
|
||||
y=0
|
||||
type=*
|
||||
[image]
|
||||
layer=-1000
|
||||
name={IMAGESTEM}
|
||||
[/image]
|
||||
[/tile]
|
||||
no_flag="base"
|
||||
set_flag="base"
|
||||
precedence=9999
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
||||
|
||||
|
||||
#define FLAG_IF_ADJACENT TERRAIN ADJACENT FLAG
|
||||
[terrain_graphics]
|
||||
map="
|
||||
, 2
|
||||
., .
|
||||
, 1
|
||||
., .
|
||||
, ."
|
||||
[tile]
|
||||
pos=1
|
||||
type={TERRAIN}
|
||||
set_flag={FLAG}
|
||||
no_flag={FLAG}
|
||||
[/tile]
|
||||
[tile]
|
||||
pos=2
|
||||
type={ADJACENT}
|
||||
[/tile]
|
||||
rotations=n,ne,se,s,sw,nw
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
||||
#define TERRAIN_BASE_FL TERRAIN_PATTERN IMAGESTEM FLAG LAYER
|
||||
{TERRAIN_BASE_LF ({TERRAIN_PATTERN}) {LAYER} {FLAG} {IMAGESTEM}}
|
||||
#enddef
|
||||
|
||||
#define TERRAIN_BASE_PROB_FL TERRAIN_PATTERN IMAGESTEM PROB FLAG LAYER
|
||||
{TERRAIN_BASE_PLF ({TERRAIN_PATTERN}) {PROB} {LAYER} {FLAG} {IMAGESTEM}}
|
||||
#enddef
|
||||
#define TERRAIN_BASE_PROB TERRAIN_PATTERN IMAGESTEM PROB
|
||||
{TERRAIN_BASE_PLF ({TERRAIN_PATTERN}) {PROB} -1000 base {IMAGESTEM}}
|
||||
#enddef
|
||||
#define TERRAIN_BASE_PROB_OV TERRAIN_PATTERN IMAGESTEM PROB
|
||||
{OVERLAY_PL ({TERRAIN_PATTERN}) {PROB} -80 {IMAGESTEM}}
|
||||
#enddef
|
||||
|
@ -1,13 +1,5 @@
|
||||
#textdomain wesnoth
|
||||
|
||||
#define VIMG BASE_STRING NAME_STRING
|
||||
[image]
|
||||
name={NAME_STRING}
|
||||
base={BASE_STRING}
|
||||
[/image]
|
||||
|
||||
#enddef
|
||||
|
||||
# This utility macro disables standard transitions on a given terrain type. It
|
||||
# is used for castles and keeps, as those have custom transitions.
|
||||
|
||||
@ -50,90 +42,9 @@
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
||||
# This utility macro sets a flag on a given terrain, if it is adjacent to an
|
||||
# other terrain.
|
||||
# Example:
|
||||
# {FLAG_IF_ADJACENT Kud Cud keep-of-castle} flags all Kud tiles
|
||||
# adjacent to Cud tiles with the keep-of-castle flag
|
||||
#
|
||||
# Use this to make other rule depend on adjacent terrain
|
||||
|
||||
#define FLAG_IF_ADJACENT TERRAIN ADJACENT FLAG
|
||||
[terrain_graphics]
|
||||
map="
|
||||
, 2
|
||||
., .
|
||||
, 1
|
||||
., .
|
||||
, ."
|
||||
[tile]
|
||||
pos=1
|
||||
type={TERRAIN}
|
||||
set_flag={FLAG}
|
||||
no_flag={FLAG}
|
||||
[/tile]
|
||||
[tile]
|
||||
pos=2
|
||||
type={ADJACENT}
|
||||
[/tile]
|
||||
rotations=n,ne,se,s,sw,nw
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
||||
|
||||
# Attaches an image to all terrain types matching
|
||||
# a specified pattern, with a given probability.
|
||||
# Example: {TERRAIN_BASE_PROBABILITY Gg grassland-rocks 20}
|
||||
|
||||
#define TERRAIN_BASE_PROB_FL TERRAIN_PATTERN IMAGESTEM PROB FLAG LAYER
|
||||
[terrain_graphics]
|
||||
[tile]
|
||||
x=0
|
||||
y=0
|
||||
type="{TERRAIN_PATTERN}"
|
||||
[image]
|
||||
layer={LAYER}
|
||||
name={IMAGESTEM}
|
||||
[/image]
|
||||
[/tile]
|
||||
|
||||
probability={PROB}
|
||||
no_flag={FLAG}
|
||||
set_flag={FLAG}
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
||||
# Same as above, but with 100% probability
|
||||
# example: {TERRAIN_BASE g grassland}
|
||||
# Should be last on the list: when a terrain has been placed, no other one can.
|
||||
|
||||
#define TERRAIN_BASE_FL TERRAIN_PATTERN IMAGESTEM FLAG LAYER
|
||||
{TERRAIN_BASE_PROB_FL ({TERRAIN_PATTERN}) {IMAGESTEM} 100 {FLAG} {LAYER}}
|
||||
#enddef
|
||||
|
||||
#define TERRAIN_BASE_PROB TERRAIN_PATTERN IMAGESTEM PROB
|
||||
{TERRAIN_BASE_PROB_FL ({TERRAIN_PATTERN}) {IMAGESTEM} {PROB} base -1000}
|
||||
#enddef
|
||||
#define TERRAIN_BASE_PROB_OV TERRAIN_PATTERN IMAGESTEM PROB
|
||||
{TERRAIN_BASE_PROB_FL ({TERRAIN_PATTERN}) {IMAGESTEM} {PROB} overlay -80}
|
||||
#enddef
|
||||
# used by bridges and rails, need some rethinking at that level
|
||||
# in particular, they want to be drawn below walls (whereas great tree and most overlays want to be drawn over walls
|
||||
#define TERRAIN_BASE_OV TERRAIN_PATTERN IMAGESTEM
|
||||
{TERRAIN_BASE_FL ({TERRAIN_PATTERN}) {IMAGESTEM} overlay -80}
|
||||
{OVERLAY_L ({TERRAIN_PATTERN}) -80 {IMAGESTEM}}
|
||||
#enddef
|
||||
|
||||
#define TERRAIN_BASE_DEFAULT IMAGESTEM
|
||||
[terrain_graphics]
|
||||
[tile]
|
||||
x=0
|
||||
y=0
|
||||
type=*
|
||||
[image]
|
||||
layer=-1000
|
||||
name={IMAGESTEM}
|
||||
[/image]
|
||||
[/tile]
|
||||
no_flag="base"
|
||||
set_flag="base"
|
||||
precedence=9999
|
||||
[/terrain_graphics]
|
||||
#enddef
|
||||
|
Loading…
x
Reference in New Issue
Block a user