Skip to content

Clauses

File: config/frontier/clauses.conf

Clauses define battle rules and restrictions. Each clause is enforced at a specific point — before battle (team validation), during battle (in-battle), or by the Showdown engine (native). Formats reference clauses by ID.

clauses {
species_clause {
displayName = "Species Clause"
description = "A player cannot have two of the same species of Pokemon on their team."
type = "TEAM_VALIDATION"
showdownRule = "Species Clause"
perPokemon = false
molangExpression = ["!query.has_duplicate_species"]
failureMessage = "Species Clause: Your team has duplicate species"
}
}
FieldTypeDefaultDescription
displayNameString""Human-readable name shown in GUIs.
descriptionString""What this clause does.
typeClauseType"SHOWDOWN_NATIVE"When and how the clause is enforced.
showdownRuleString?nullShowdown rule string (for SHOWDOWN_NATIVE clauses).
molangExpressionList<String>?nullMoLang expressions for validation. Each entry is a separate expression.
perPokemonBooleantrueIf true, expression runs once per Pokemon. If false, once for the whole team.
failureMessageString?nullMessage shown when validation fails. Placeholders: {pokemon} (per-Pokemon only), {clause}.
TypeDescription
TEAM_VALIDATIONChecked during team validation before the battle starts. Uses MoLang expressions.
SHOWDOWN_NATIVEPassed directly to the Showdown battle engine as a rule string.
IN_BATTLEEnforced during battle by Frontier (gimmick bans).
  1. Queue JoinTEAM_VALIDATION clauses run against the player’s team. If any fail, the player can’t join the queue and sees the failure message.
  2. Battle StartSHOWDOWN_NATIVE clauses are passed to the Showdown engine. Format-level bans (species, moves, abilities, items) also apply here.
  3. During BattleIN_BATTLE clauses (gimmick bans) fire when players attempt banned mechanics.

Frontier ships with 13 clauses across all three types.

IDNamePer-PokemonExpressionDescription
species_clauseSpecies ClauseNo!query.has_duplicate_speciesNo duplicate species on a team.
item_clauseItem ClauseNo!query.has_duplicate_itemsNo duplicate held items.
evasion_clauseEvasion ClauseYes!query.pokemon.has_any_move('doubleteam,minimize')Bans evasion-boosting moves.
ohko_clauseOHKO ClauseYes!query.pokemon.has_any_move('fissure,sheercold,horndrill,guillotine')Bans one-hit KO moves.
monotypeMonotypeNoquery.team_shares_typeAll team members must share a type.
level_capLevel CapYesquery.format_target_level == 0 || query.pokemon.level <= query.format_target_levelPokemon must be at or below the format’s target level.
no_legendariesNo LegendariesYes!query.pokemon.species.has_label('legendary')Legendary Pokemon are banned.
nfe_onlyNFE OnlyYesquery.pokemon.can_evolveOnly unevolved Pokemon (Little Cup).
IDNameShowdown RuleDescription
sleep_clauseSleep Clause"Sleep Clause Mod"Only one opposing Pokemon can be asleep at a time.
IDNameWhat It Bans
gimmick_banGimmick BanMega Evolution, Ultra Burst, Z-Moves, Dynamax, Terastallization
ban_megaMega Evolution BanMega Evolution, Ultra Burst
ban_teraTerastallization BanTerastallization
ban_dynamaxDynamax BanDynamax
ban_zmovesZ-Moves BanZ-Moves

Frontier exposes custom MoLang queries for use in clause expressions.

Available when perPokemon = true. Access through query.pokemon.

QueryReturnsDescription
query.pokemon.levelDoublePokemon’s current level.
query.pokemon.can_evolve1.0/0.0Whether the Pokemon can still evolve.
query.pokemon.has_move('name')1.0/0.0Whether the Pokemon knows a specific move (Showdown ID).
query.pokemon.has_any_move('m1,m2,...')1.0/0.0Whether the Pokemon knows any of the listed moves.
query.pokemon.species.has_label('label')1.0/0.0Whether the species has a label (e.g., legendary).

Available in both per-Pokemon and team mode.

QueryReturnsDescription
query.team_sizeDoubleNumber of Pokemon on the team.
query.has_duplicate_species1.0/0.0Whether the team has duplicate species.
query.has_duplicate_items1.0/0.0Whether the team has duplicate held items.
query.team_shares_type1.0/0.0Whether all team members share at least one type.
query.format_target_levelDoubleFormat’s target level (0 if none).
query.format_team_sizeDoubleFormat’s max team size.

You can define your own clauses with MoLang expressions. Here are two examples:

clauses {
no_uber_abilities {
displayName = "No Uber Abilities"
description = "Bans Shadow Tag and Arena Trap."
type = "TEAM_VALIDATION"
perPokemon = true
molangExpression = [
"query.pokemon.ability.name != 'shadowtag' && query.pokemon.ability.name != 'arenatrap'"
]
failureMessage = "{pokemon} has a banned ability"
}
max_level_50 {
displayName = "Level 50 Cap"
description = "All Pokemon must be level 50 or below."
type = "TEAM_VALIDATION"
perPokemon = true
molangExpression = ["query.pokemon.level <= 50"]
failureMessage = "{pokemon} exceeds the level 50 cap"
}
}