Skip to content

Commit

Permalink
Use a few more conditional tag elements
Browse files Browse the repository at this point in the history
  • Loading branch information
CelticMinstrel committed Oct 24, 2018
1 parent ed7c3db commit 65ef124
Showing 1 changed file with 27 additions and 10 deletions.
37 changes: 27 additions & 10 deletions data/schema/core/addons.cfg
Expand Up @@ -107,9 +107,13 @@
{SIMPLE_KEY leader string}
{SIMPLE_KEY random_leader string}
{DEFAULT_KEY random_faction bool no}
# TODO: below two keys only valid if above key is yes
{SIMPLE_KEY choices string_list}
{SIMPLE_KEY except string_list}
[if]
random_faction=no
[then]
{SIMPLE_KEY choices string_list}
{SIMPLE_KEY except string_list}
[/then]
[/if]
{SIMPLE_KEY terrain_liked terrain_list}
[/tag]

Expand Down Expand Up @@ -195,10 +199,17 @@
[/tag]
# Multiplayer specific
# TODO: These are probably only allowed if type is mp or hybrid?
{DEFAULT_KEY min_players int 2}
{SIMPLE_KEY max_players int}
{DEFAULT_KEY allow_era_choice bool yes}
{DEFAULT_KEY require_campaign bool yes}
[if]
[not]
type=sp
[/not]
[then]
{DEFAULT_KEY min_players int 2}
{SIMPLE_KEY max_players int}
{DEFAULT_KEY allow_era_choice bool yes}
{DEFAULT_KEY require_campaign bool yes}
[/then]
[/if]
[/tag]
[tag]
name="era"
Expand Down Expand Up @@ -298,9 +309,15 @@
{SIMPLE_KEY victory_music string}
{SIMPLE_KEY theme string_list}
{DEFAULT_KEY victory_when_enemies_defeated bool yes}
# TODO: The following two keys are only valid if the above key is yes (or omitted)
{SIMPLE_KEY carryover_percentage int}
{SIMPLE_KEY carryover_add bool}
[if]
[not]
victory_when_enemies_defeated=no
[/not]
[then]
{SIMPLE_KEY carryover_percentage int}
{SIMPLE_KEY carryover_add bool}
[/then]
[/if]
{DEFAULT_KEY remove_from_carryover_on_defeat bool yes}
{DEFAULT_KEY disallow_recall bool no}
{DEFAULT_KEY experience_modifier int_percent 100}
Expand Down

0 comments on commit 65ef124

Please sign in to comment.