diff --git a/data/magic-extended-art.mse-style/style b/data/magic-extended-art.mse-style/style index 2114a879..2ac08f3f 100644 --- a/data/magic-extended-art.mse-style/style +++ b/data/magic-extended-art.mse-style/style @@ -207,7 +207,7 @@ card style: then "magic-mana-large" else "magic-mana-small" size: 14 - alignment: middle left + alignment: bottom left z index: 2 padding left: 6 padding top: 2 diff --git a/data/magic-textless.mse-style/style b/data/magic-textless.mse-style/style index f4a5a011..30e3edc8 100644 --- a/data/magic-textless.mse-style/style +++ b/data/magic-textless.mse-style/style @@ -62,12 +62,27 @@ styling field: name: use guild mana symbols description: Use the Ravnica guild symbols instead of the official half/half circles for hybrid mana. initial: no +styling field: + type: choice + name: tap symbol + description: What tap symbol should be used on cards? + initial: modern + choice: modern + choice: old + choice: diagonal T styling style: use guild mana symbols: choice images: yes: /magic-mana-small.mse-symbol-font/mana_guild_rg.png no: /magic-mana-small.mse-symbol-font/mana_rg.png + tap symbol: + render style: both + choice images: + modern: /magic-mana-large.mse-symbol-font/mana_t.png + old: /magic-mana-large.mse-symbol-font/mana_t_old.png + diagonal T: /magic-mana-large.mse-symbol-font/mana_t_older.png + ############################################################## Card fields card style: diff --git a/data/magic.mse-game/game b/data/magic.mse-game/game index 549ae0f4..b3825181 100644 --- a/data/magic.mse-game/game +++ b/data/magic.mse-game/game @@ -234,6 +234,18 @@ init script: replace_rule( match: "s" replace: "" ) + + # step 6d : "." remover for keywords + replace_rule( + match: ".<.>" + replace: "" ) + + # step 6e : p/t detector, needed for suspend + tag_contents_rule( + tag: "" + contents: { if card.pt == "" then "" else contents } ) + + # step 6f : casting cost detector, needed for suspend + tag_contents_rule(## by somebloke + tag: "" + contents: { if card.casting_cost == "" then "" else contents } ) + # step 7 : italic reminder text replace_rule( match: "[(][^)\n]*[)]?", @@ -242,7 +254,7 @@ init script: # step 8 : post ( capitalization replace_rule( match: "[a-z]", - in_context: "[(]()?", + in_context: "[(]()?|[ ]*: ", replace: { to_upper() }) # the flavor text filter @@ -424,6 +436,13 @@ card field: # Specify the colors somewhere else, to keep things clean include file: magic-blends.mse-include/card-colors default: card_color(casting_cost: card.casting_cost) +#needed for FPM temps +card field: + type: choice + name: font color + choice: black + choice: white + description: Font color for the typeline and textbox ############################# Name line card field: @@ -491,7 +510,13 @@ card field: card list visible: true card list column:4 description: The type of this card, type - to go the sub type - +#needed for FPM temps +card field: + type: choice + name: type image + include file: magic-blends.mse-include/card-colors + script: card.card_color + editable: false card field: type: choice name: rarity @@ -527,7 +552,15 @@ card field: show statistics: false script: combined_editor(field1: card.rule_text, separator: "\n", field2: card.flavor_text) - +#needed for FPM temps +card field: + type: choice + name: textbox + include file: magic-blends.mse-include/card-colors + script: card.card_color + editable: false + save value: false + show statistics: false card field: type: choice name: watermark @@ -582,6 +615,13 @@ card field: name: toughness icon: stats/toughness.png editable: false +#needed for FPM temps +card field: + type: choice + name: ptsymbols + choice: shieldsword + editable: false + show statistics: false card field: type: text name: pt @@ -770,6 +810,13 @@ card field: icon: stats/toughness.png editable: false show statistics: false +#needed for FPM temps +card field: + type: choice + name: ptsymbols 2 + choice: shieldsword + editable: false + show statistics: false card field: type: text name: pt 2 @@ -980,9 +1027,17 @@ keyword parameter type: description: standard cost script: \{{input}\} refer script: - name: dual parameters + name: add = nothing description: parses dual costs without pay an additional script: \{format_cost({input},add:"")\} + refer script: + name: add = "pay an additional " + description: parses dual costs without pay an additional + script: \{format_cost({input},add:"pay an additional ")\} + refer script: + name: add = "pay " + description: parses dual costs without pay an additional + script: \{format_cost({input},add:"pay ")\} keyword parameter type: name: number match: [XYZ0-9]+ @@ -1082,7 +1137,7 @@ keyword: keyword: Cumulative upkeep match: Cumulative upkeepcost mode: old - reminder: At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you {format_cost(param1,add:"pay an additional ")} for each age counter on it. + reminder: At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you {format_cost(param1,add:"pay ")} for each age counter on it. keyword: keyword: Horsemanship match: Horsemanship @@ -1107,7 +1162,7 @@ keyword: keyword: Buyback match: Buybackcost mode: expert - reminder: You may pay {format_cost(param1,add:"pay an additional ")} in addition to any other costs as you play this spell. If you do, put this card into your hand as it resolves. + reminder: You may pay {format_cost(param1,add:"pay ")} in addition to any other costs as you play this spell. If you do, put this card into your hand as it resolves. keyword: keyword: Echo match: Echocost @@ -1117,12 +1172,7 @@ keyword: keyword: Cardcycling match: namecyclingcost mode: expert - reminder: {format_cost(param1,add:"")}, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. -keyword: - keyword: Cardcycling - match: namecycling—action - mode: expert - reminder: {param2}, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. + reminder: {format_cost(param2,add:"")}, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. keyword: keyword: Fading match: Fading number @@ -1132,7 +1182,7 @@ keyword: keyword: Kicker match: Kickercost mode: expert - reminder: You may pay an additional {format_cost(param1,add:"pay an additional ")} as you play this spell. + reminder: You may {format_cost(param1,add:"pay an additional ")} as you play this spell. keyword: keyword: Madness match: Madnesscost @@ -1205,7 +1255,7 @@ keyword: reminder: This comes into play with a +1/+1 counter on it for each color of mana used to pay its cost. If it is not a creature, use charge counters instead. keyword: keyword: Splice - match: Splice onto namecost + match: Splice onto name cost mode: expert reminder: As you play a {param1} spell, you may reveal this card from your hand and pay its splice cost. If you do, add this card’s effects to that spell. keyword: @@ -1286,14 +1336,14 @@ keyword: reminder: This creature comes into play with {english_number_a(param1)} +1/+1 counter(s) on it. Whenever another creature comes into play, you may move a +1/+1 counter from this creature onto it. keyword: keyword: Forecast - match: Forecast — cost, Reveal ~ from your hand: action. + match: Forecast—cost, Reveal this card from your hand: action mode: expert reminder: Play this ability only during your upkeep and only once each turn. keyword: keyword: Recover match: Recovercost mode: expert - reminder: When a creature is put into your graveyard from play, you may pay an additional {format_cost(param1,add:"pay an additional ")}. If you do, return this card from your graveyard to your hand. Otherwise, remove this card from the game. + reminder: When a creature is put into your graveyard from play, you may {format_cost(param1,add:"pay ")}. If you do, return this card from your graveyard to your hand. Otherwise, remove this card from the game. keyword: keyword: Ripple match: Ripple number @@ -1313,7 +1363,7 @@ keyword: keyword: Suspend match: Suspend numbermana mode: expert - reminder: Rather than play this card from your hand, you may pay {param2} and remove it from the game with {english_number_a(param1)} time counter(s) on it. At the beginning of your upkeep, remove a time counter. When the last is removed, play it without paying its mana cost. It has haste. + reminder: Rather than play this card from your hand, you may pay {param2} and remove it from the game with {english_number_a(param1)} time counter(s) on it. At the beginning of your upkeep, remove a time counter. When the last is removed, play it without paying its mana cost. It has haste. keyword: keyword: Vanishing match: Vanishing number @@ -1356,7 +1406,7 @@ keyword: reminder: {format_cost(param1,add:"")}, Sacrifice this creature: Search your library for a creature card with the same converted mana cost as this creature and put that card into play. Then shuffle your library. Play only as a sorcery. keyword: keyword: Aura swap - match: Aura swampcost + match: Aura swapcost mode: expert reminder: {format_cost(param1,add:"")}: Exchange this Aura with an Aura card in your hand. keyword: diff --git a/data/vanguard.mse-game/game b/data/vanguard.mse-game/game index a94d1f67..e5af311d 100644 --- a/data/vanguard.mse-game/game +++ b/data/vanguard.mse-game/game @@ -26,7 +26,7 @@ init script: replace: "™") + # step 4 : copyright symbol replace_rule( - match: "(C)", + match: "CR", replace: "©") #character filter for title line @@ -60,6 +60,14 @@ init script: replace: "" ) + { tap_filter() + mana_filter() } + # replaces — correctly + alternative_cost := replace_rule(match:"—|\\.", replace:"") + replace_rule(match:"[A-Z]", in_context:"", replace: { to_lower() }) + mana_cost := replace_rule(match:" ", in_context:"\\>", replace: "") + format_cost := { + if substring(begin: 0, end: 13)=="—" then + alternative_cost(input:input) + else add + "" + mana_cost(input:input) + "" + }; # Filters for the text box # context in which mana symbols are found @@ -81,7 +89,7 @@ init script: ) ) | # keyword argument that is declared as mana - | # keyword argument that is declared as cost + | [ ]* # keyword argument that is declared as cost | , # keyword argument that is declared as cost "; # the rule text filter @@ -91,6 +99,11 @@ init script: # step 1 : remove all automatic tags tag_remove_rule(tag: "") + tag_remove_rule(tag: "") + + # step 2 : reminder text for keywords + expand_keywords_rule( + default_expand: { contains(match:mode, set.automatic_reminder_text, match:mode) }, + combine: { "{keyword} ({process_english_hints(reminder)})" } + ) + # step 3 : expand shortcut words ~ and CARDNAME replace_rule( match: "~|~THIS~|CARDNAME", @@ -131,11 +144,24 @@ init script: replace_rule( match: ".<.>" replace: "" ) + + # step 6e : p/t detector, needed for suspend + tag_contents_rule( + tag: "" + contents: { if card.pt == "" then "" else contents } ) + + # step 6f : casting cost detector, needed for suspend + tag_contents_rule(## by somebloke + tag: "" + contents: { if card.casting_cost == "" then "" else contents } ) + # step 7 : italic reminder text replace_rule( match: "[(][^)\n]*[)]?", in_context: "(^|[[:space:]])|", - replace: "&"); + replace: "&") + + # step 8 : post ( capitalization + replace_rule( + match: "[a-z]", + in_context: "[(]()?|[ ]*: ", + replace: { to_upper() }) ############################################################## Set fields @@ -175,6 +201,20 @@ set field: choice: name: gold color: rgb(200,180,0) +set field: + type: multiple choice + name: automatic reminder text + choice: old + choice: core + choice: expert + choice: custom + initial: old, core, expert, custom + # Convert from older mse versions + script: + if value = "yes" then "old, core, expert, custom" + else if value = "no" then "" + else value + description: For which kinds of keywords should reminder text be added by default? Note: you can enable/disable reminder text by right clicking the keyword. set field: type: boolean name: automatic card numbers @@ -336,10 +376,26 @@ keyword mode: keyword parameter type: name: mana match: [XYZ0-9WUBRGS/]+ -# By jimrandomh +# By pichoro and bunnierein keyword parameter type: name: cost - match: [^(\n]+ + match: [:space:]?[^(\n]+ + refer script: + name: normal + description: standard cost + script: \{{input}\} + refer script: + name: add = nothing + description: parses dual costs without pay an additional + script: \{format_cost({input},add:"")\} + refer script: + name: add = "pay an additional " + description: parses dual costs without pay an additional + script: \{format_cost({input},add:"pay an additional ")\} + refer script: + name: add = "pay " + description: parses dual costs without pay an additional + script: \{format_cost({input},add:"pay ")\} keyword parameter type: name: number match: [XYZ0-9]+ @@ -373,7 +429,7 @@ keyword parameter type: example: Forest ############################# All Magic keywords -# By JrEye and Neko_Asakami +# By JrEye and Neko_Asakami, updated by Buttock1234 and Pichoro keyword: keyword: Flying @@ -402,14 +458,9 @@ keyword: reminder: Target a {param1} as you play this. This card comes into play attached to that {param1}. keyword: keyword: Cycling - match: Cycling mana + match: Cyclingcost mode: core - reminder: {param1}, Discard this card: Draw a card. -keyword: - keyword: Cycling - match: Cycling—action - mode: core - reminder: {param1}<.>, Discard this card: Draw a card. + reminder: {format_cost(param1,add:"")}, Discard this card: Draw a card. keyword: keyword: Trample match: Trample @@ -442,14 +493,9 @@ keyword: reminder: This creature can’t attack. keyword: keyword: Cumulative upkeep - match: Cumulative upkeep mana + match: Cumulative upkeepcost mode: old - reminder: At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay {param1} for each age counter on it. -keyword: - keyword: Cumulative upkeep - match: Cumulative upkeep—action - mode: old - reminder: At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you {to_lower(param1)}<.> for each age counter on it. + reminder: At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you {format_cost(param1,add:"pay ")} for each age counter on it. keyword: keyword: Horsemanship match: Horsemanship @@ -472,34 +518,19 @@ keyword: reminder: This creature can block or be blocked only by creatures with shadow. keyword: keyword: Buyback - match: Buyback mana + match: Buybackcost mode: expert - reminder: You may pay {param1} in addition to any other costs as you play this spell. If you do, put this card into your hand as it resolves. -keyword: - keyword: Buyback - match: Buyback—action - mode: expert - reminder: You may {to_lower(param1)}<.> in addition to any other costs as you play this spell. If you do, put this card into your hand as it resolves. + reminder: You may pay {format_cost(param1,add:"pay ")} in addition to any other costs as you play this spell. If you do, put this card into your hand as it resolves. keyword: keyword: Echo - match: Echo mana - mode: expert - reminder: At the beginning of your upkeep, if this came under your control since the beginning of your last upkeep, sacrifice it unless you pay its echo cost. -keyword: - keyword: Echo - match: Echo—action + match: Echocost mode: expert reminder: At the beginning of your upkeep, if this came under your control since the beginning of your last upkeep, sacrifice it unless you pay its echo cost. keyword: keyword: Cardcycling - match: namecycling mana + match: namecyclingcost mode: expert - reminder: {param2}, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. -keyword: - keyword: Cardcycling - match: namecycling—action - mode: expert - reminder: {param2}<.>, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. + reminder: {format_cost(param2,add:"")}, Discard this card: Search your library for a {param1} card, reveal it, and put it into your hand. Then shuffle your library. keyword: keyword: Fading match: Fading number @@ -507,42 +538,22 @@ keyword: reminder: This comes into play with {english_number_a(param1)} fade counter(s) on it. At the beginning of your upkeep, remove a fade counter from it. If you can’t, sacrifice it. keyword: keyword: Kicker - match: Kicker mana + match: Kickercost mode: expert - reminder: You may pay an additional {param1} as you play this spell. -keyword: - keyword: Kicker - match: Kicker—action - mode: expert - reminder: You may {to_lower(param1)}<.> as you play this spell. + reminder: You may {format_cost(param1,add:"pay an additional ")} as you play this spell. keyword: keyword: Madness - match: Madness mana - mode: expert - reminder: You may play this card for its madness cost at the time you discard it. -keyword: - keyword: Madness - match: Madness—action + match: Madnesscost mode: expert reminder: You may play this card for its madness cost at the time you discard it. keyword: keyword: Flashback - match: Flashback mana - mode: expert - reminder: You may play this card from your graveyard for its flashback cost. Then remove it from the game. -keyword: - keyword: Flashback - match: Flashback—action + match: Flashbackcost mode: expert reminder: You may play this card from your graveyard for its flashback cost. Then remove it from the game. keyword: keyword: Morph - match: Morph mana - mode: expert - reminder: You may play this face down as a 2/2 creature for 3. Turn it face up any time for its morph cost. -keyword: - keyword: Morph - match: Morph—action + match: Morphcost mode: expert reminder: You may play this face down as a 2/2 creature for 3. Turn it face up any time for its morph cost. keyword: @@ -572,24 +583,14 @@ keyword: reminder: This spell costs 1 less to play for each {param1} you control. keyword: keyword: Entwine - match: Entwine mana - mode: expert - reminder: Choose both if you pay the entwine cost. -keyword: - keyword: Entwine - match: Entwine—action + match: Entwinecost mode: expert reminder: Choose both if you pay the entwine cost. keyword: keyword: Equip - match: Equip mana + match: Equipcost mode: expert - reminder: {param1}: Attach to target creature you control. Equip only as a sorcery. -keyword: - keyword: Equip - match: Equip—action - mode: expert - reminder: {param1}<.>: Attach to target creature you control. Equip only as a sorcery. + reminder: {format_cost(param1,add:"")}: Attach to target creature you control. Equip only as a sorcery. keyword: keyword: Imprint match: Imprint—action @@ -612,14 +613,9 @@ keyword: reminder: This comes into play with a +1/+1 counter on it for each color of mana used to pay its cost. If it is not a creature, use charge counters instead. keyword: keyword: Splice - match: Splice onto name mana + match: Splice onto name cost mode: expert reminder: As you play a {param1} spell, you may reveal this card from your hand and pay its splice cost. If you do, add this card’s effects to that spell. -keyword: - keyword: Splice - match: Splice onto nameaction - mode: expert - reminder: As you play a {param1} spell, you may reveal this card from your hand and pay its splice cost. If you do, add this card's effects to that spell. keyword: keyword: Offering match: name offering @@ -632,14 +628,9 @@ keyword: reminder: When this blocks or becomes blocked, it gets +{param1}/+{param1} until end of turn. keyword: keyword: Ninjutsu - match: Ninjutsu mana + match: Ninjutsucost mode: expert - reminder: {param1}, Return an unblocked attacker you control to hand: Put this card into play from your hand tapped and attacking. -keyword: - keyword: Ninjutsu - match: Ninjutsu—action - mode: expert - reminder: {param1}<.>, Return an unblocked attacker you control to hand: Put this card into play from your hand tapped and attacking. + reminder: {format_cost(param1,add:"")}, Return an unblocked attacker you control to hand: Put this card into play from your hand tapped and attacking. keyword: keyword: Soulshift match: Soulshift number @@ -657,14 +648,9 @@ keyword: reminder: Each creature you tap while playing this spell reduces its cost by 1 or by one mana of that creature’s color. keyword: keyword: Transmute - match: Transmute mana + match: Transmutecost mode: expert - reminder: {param1}, Discard this card: Search your library for a card with the same converted mana cost as this card, reveal it, and put it into your hand. Then shuffle your library. Play only as a sorcery. -keyword: - keyword: Transmute - match: Transmute—action - mode: expert - reminder: {param1}<.>, Discard this card: Search your library for a card with the same converted mana cost as this card, reveal it, and put it into your hand. Then shuffle your library. Play only as a sorcery. + reminder: {format_cost(param1,add:"")}, Discard this card: Search your library for a card with the same converted mana cost as this card, reveal it, and put it into your hand. Then shuffle your library. Play only as a sorcery. keyword: keyword: Haunt match: Haunt @@ -677,12 +663,7 @@ keyword: reminder: If an opponent was dealt damage this turn, this creature comes into play with {english_number_a(param1)} +1/+1 counter(s) on it. keyword: keyword: Replicate - match: Replicate mana - mode: expert - reminder: When you play this spell, copy it for each time you paid its replicate cost. You may choose new targets for the copies. -keyword: - keyword: Replicate - match: Replicate—action + match: Replicatecost mode: expert reminder: When you play this spell, copy it for each time you paid its replicate cost. You may choose new targets for the copies. #Denimwalk was a casualty of my fixing landwalk to work right @@ -713,19 +694,14 @@ keyword: reminder: This creature comes into play with {english_number_a(param1)} +1/+1 counter(s) on it. Whenever another creature comes into play, you may move a +1/+1 counter from this creature onto it. keyword: keyword: Forecast - match: Forecast — cost, Reveal ~ from your hand: action. + match: Forecast—cost, Reveal this card from your hand: action mode: expert reminder: Play this ability only during your upkeep and only once each turn. keyword: keyword: Recover - match: Recover mana + match: Recovercost mode: expert - reminder: When a creature is put into your graveyard from play, you may pay an additional {param1}. If you do, return this card from your graveyard to your hand. Otherwise, remove this card from the game. -keyword: - keyword: Recover - match: Recover—action - mode: expert - reminder: When a creature is put into your graveyard from play, you may {to_lower(param1)}<.>. If you do, return this card from your graveyard to your hand. Otherwise, remove this card from the game. + reminder: When a creature is put into your graveyard from play, you may {format_cost(param1,add:"pay ")}. If you do, return this card from your graveyard to your hand. Otherwise, remove this card from the game. keyword: keyword: Ripple match: Ripple number @@ -745,7 +721,7 @@ keyword: keyword: Suspend match: Suspend numbermana mode: expert - reminder: Rather than play this card from your hand, you may pay {param2} and remove it from the game with {english_number_a(param1)} time counter(s) on it. At the beginning of your upkeep, remove a time counter. When the last is removed, play it without paying its mana cost. It has haste. + reminder: Rather than play this card from your hand, you may pay {param2} and remove it from the game with {english_number_a(param1)} time counter(s) on it. At the beginning of your upkeep, remove a time counter. When the last is removed, play it without paying its mana cost. It has haste. keyword: keyword: Vanishing match: Vanishing number @@ -783,24 +759,14 @@ keyword: reminder: Look at the top {english_number_multiple(param1)} card(s) of an opponent's library, then put any number of them on the bottom of that player's library and the rest on top in any order. keyword: keyword: Transfigure - match: Transfigure mana + match: Transfigurecost mode: expert - reminder: {param1}, Sacrifice this creature: Search your library for a creature card with the same converted mana cost as this creature and put that card into play. Then shuffle your library. Play only as a sorcery. -keyword: - keyword: Transfigure - match: Transfigure—action - mode: expert - reminder: {param1}<.>, Sacrifice this creature: Search your library for a creature card with the same converted mana cost as this creature and put that card into play. Then shuffle your library. Play only as a sorcery. + reminder: {format_cost(param1,add:"")}, Sacrifice this creature: Search your library for a creature card with the same converted mana cost as this creature and put that card into play. Then shuffle your library. Play only as a sorcery. keyword: keyword: Aura swap - match: Aura swamp mana + match: Aura swapcost mode: expert - reminder: {param1}: Exchange this Aura with an Aura card in your hand. -keyword: - keyword: Aura swap - match: Aura swap—action - mode: expert - reminder: {param1}<.>: Exchange this Aura with an Aura card in your hand. + reminder: {format_cost(param1,add:"")}: Exchange this Aura with an Aura card in your hand. keyword: keyword: Frenzy match: Frenzy number @@ -823,11 +789,6 @@ keyword: reminder: This permanent can't be the target of spells or abilities. keyword: keyword: Fortify - match: Fortify mana + match: Fortifycost mode: expert - reminder: {param1}<.>: Attach to target land you control. Fortify only as a sorcery. This card comes into play unattached and stays in play if the land leaves play. -keyword: - keyword: Fortify - match: Fortify—action - mode: expert - reminder: {param1}<.>: Attach to target land you control. Fortify only as a sorcery. This card comes into play unattached and stays in play if the land leaves play. + reminder: {format_cost(param1,add:"")}: Attach to target land you control. Fortify only as a sorcery. This card comes into play unattached and stays in play if the land leaves play.