[tag] name="goal" super="$ai/$component" {SIMPLE_KEY value real} [if] engine=lua [then] [switch] key=name [case] value=lua_goal {SIMPLE_KEY code string} [/case] [else] # This required key is just a hack to get an error here. # It's not actually valid. {REQUIRED_KEY invalid_name_in_goal_with_lua_engine bool} [/else] [/switch] [/then] [else] [switch] key=name [case] value=target,target_unit trigger_if_missing=yes {FILTER_TAG criteria unit ()} [/case] [case] value=target_location {FILTER_TAG criteria location ()} [/case] [case] value=protect_unit,protect_my_unit {FILTER_TAG criteria unit ()} {SIMPLE_KEY protect_radius int} [/case] [case] value=protect_location {FILTER_TAG criteria location ()} {SIMPLE_KEY protect_radius int} [/case] [else] # This required key is just a hack to get an error here. # It's not actually valid. {REQUIRED_KEY invalid_name_in_goal_with_cpp_engine bool} [/else] [/switch] [/else] [/if] [/tag] # Deprecated versions {FILTER_TAG target unit ( deprecated=yes {SIMPLE_KEY value real} )} {FILTER_TAG target_location location ( deprecated=yes {SIMPLE_KEY value real} )} {FILTER_TAG protect_unit unit ( deprecated=yes {SIMPLE_KEY value real} {SIMPLE_KEY protect_radius int} )} {FILTER_TAG protect_location location ( deprecated=yes {SIMPLE_KEY value real} {SIMPLE_KEY protect_radius int} )}