diff --git a/data/magic.mse-game/game b/data/magic.mse-game/game index d298a9c1..eaa0ff9f 100644 --- a/data/magic.mse-game/game +++ b/data/magic.mse-game/game @@ -5,7 +5,7 @@ installer group: magic/game files icon: card-back.png position hint: 01 -version: 2009-04-22 +version: 2009-05-28 depends on: magic-blends.mse-include 2007-09-23 depends on: magic-watermarks.mse-include 2007-09-23 diff --git a/data/magic.mse-game/script b/data/magic.mse-game/script index 0170ea60..7940451b 100644 --- a/data/magic.mse-game/script +++ b/data/magic.mse-game/script @@ -452,9 +452,9 @@ text_filter := match: "[(]([^)\n]|[(][^)\n]*[)])*[)]?", in_context: "(^|[[:space:]])|&") + - # step 8 : automatic capitalization + # step 8 : automatic capitalization, but not after "(" replace@( - match: "([(](?:)?|[ ]*: |—| — )" # preceded by this + match: "([ ]*: |—| — )" # preceded by this + "([[:lower:]])" # match this + "(?![)])", # not followed by this replace: { _1 + to_upper(_2) }) + diff --git a/data/vanguard.mse-game/game b/data/vanguard.mse-game/game index c47e0597..2f0e88ca 100644 --- a/data/vanguard.mse-game/game +++ b/data/vanguard.mse-game/game @@ -5,13 +5,11 @@ installer group: Magic Vanguard/game files icon: card-sample.png position hint: 02 -version: 2009-04-22 +version: 2009-05-28 # Author : Wolfwood # Most stuff is copy/pasted from magic.mse-game - ############################################################## Functions & filters - # General functions init script: ############################################################## Sorting mana symbols @@ -148,14 +146,14 @@ init script: ) + # step 3 : expand shortcut words ~ and CARDNAME replace@( - match: "~|~THIS~|CARDNAME", + match: "~|CARDNAME", in_context: "(^|[[:space:]]|\\()", replace: "" ) + # step 4 : fill in atom fields tag_contents@( tag: "", - contents: { if card.name=="" then "CARDNAME" else card.name } + contents: { if card.name=="" then "CARDNAME" else card.type + " - " + card.name } ) + # step 4.5 : explict non mana symbols replace@( @@ -175,10 +173,10 @@ init script: match: "[(][^)\n]*[)]?", in_context: "(^|[[:space:]])|", replace: "&") + - # step 8 : automatic capitalization + # step 8 : automatic capitalization, but not after "(" replace@( match: "[a-z]", - in_context: "[(]()?|[ ]*: |—| — ", + in_context: "[ ]*: |—| — ", replace: { to_upper() }) curly_quotes