disallow "in through <screen>"

This commit is contained in:
xeals 2023-04-27 11:58:02 +10:00
parent 0b163e8ffd
commit 6aa1cac328
Signed by: xeals
GPG Key ID: A498C7AF27EC6B5C

View File

@ -82,10 +82,12 @@ function buildLexer() {
const Weather = createToken({ const Weather = createToken({
name: "Weather", name: "Weather",
pattern: /Sun|Rain|Sand|Snow/, pattern: /Sun|Rain|Sand|Snow/,
pop_mode: true,
}); });
const Terrain = createToken({ const Terrain = createToken({
name: "Terrain", name: "Terrain",
pattern: /(Electric|Grassy|Misty|Psychic) Terrain/, pattern: /(Electric|Grassy|Misty|Psychic) Terrain/,
pop_mode: true,
}); });
const screenEnter = createToken({ const screenEnter = createToken({
@ -110,7 +112,7 @@ function buildLexer() {
terrainEnter, terrainEnter,
screenEnter, screenEnter,
], ],
terrain_mode: [whitespace, screenEnter, Weather, Terrain], terrain_mode: [whitespace, Weather, Terrain],
screen_mode: [whitespace, Move], screen_mode: [whitespace, Move],
}, },
defaultMode: "default_mode", defaultMode: "default_mode",