The in-memory representation of a [terrain_graphics] WML rule. More...
Public Member Functions | |
| bool | operator< (const building_rule &that) const |
| unsigned int | get_hash () const |
Public Attributes | |
| constraint_set | constraints |
| The set of [tile] constraints of this rule. | |
| map_location | location_constraints |
| The location on which this map may match. | |
| map_location | modulo_constraints |
| Used to constrain locations to ones with coordinates that are multiples of the "mod_x" and "mod_y" parameters. | |
| int | probability = 100 |
| The probability of this rule to match, when all conditions are met. | |
| int | precedence = 0 |
| Ordering relation between the rules. | |
| bool | local = false |
| Indicate if the rule is only for this scenario. | |
Private Attributes | |
| unsigned int | hash_ = DUMMY_HASH |
The in-memory representation of a [terrain_graphics] WML rule.
Definition at line 361 of file builder.hpp.
Definition at line 1109 of file builder.cpp.
References terrain_builder::DUMMY_HASH, hash_str(), and terrain_builder::map().
|
inline |
Definition at line 399 of file builder.hpp.
References terrain_builder::map(), and precedence.
| constraint_set terrain_builder::building_rule::constraints |
The set of [tile] constraints of this rule.
Definition at line 366 of file builder.hpp.
|
mutableprivate |
Definition at line 407 of file builder.hpp.
Indicate if the rule is only for this scenario.
Definition at line 397 of file builder.hpp.
| map_location terrain_builder::building_rule::location_constraints |
The location on which this map may match.
Set to a valid map_location if the "x" and "y" parameters of the [terrain_graphics] rule are set.
Definition at line 373 of file builder.hpp.
| map_location terrain_builder::building_rule::modulo_constraints |
Used to constrain locations to ones with coordinates that are multiples of the "mod_x" and "mod_y" parameters.
Doesn't actually refer to a real map location.
Definition at line 380 of file builder.hpp.
| int terrain_builder::building_rule::precedence = 0 |
Ordering relation between the rules.
Definition at line 392 of file builder.hpp.
Referenced by operator<().
| int terrain_builder::building_rule::probability = 100 |
The probability of this rule to match, when all conditions are met.
Defined if the "probability" parameter of the [terrain_graphics] element is set.
Definition at line 387 of file builder.hpp.