Most of the cards are based on the last adds by salmelo, while some few cards could have been added for half a year or more.
2 weeks of intensive testing are over, and I think all cards will do what they should but if you still find something discussable after testing them by yourself, plz post it here!
Card list -> First post.
use "trigger" inside target code of triggered ability.
does not work with @each and @next.
@damaged can use trigger[to] and trigger[from] to specify the target or source of the damage, respectively.
Adds cards:
Aether Flash
Bramblewood Paragon
In the Web of War
Juniper Order Ranger
Mortuary
Primal Forcemage
Fungus Sliver
Simic Initiate
as well as a test file for feral hydra, missing from my last commit.
and daily build.
It fixes several problems with the newly introduced improvements concerning Counters.
Added 8 successfully tested cards, 1 of them is DARK DEPTHS!
Daily_Build update
Complete list in the first comment.
Salmelo:"Here is another patch, this time adding counters to target specifications, so now you should be able to target things with counters on them as well as use counters for criterion for Lord, aslongas, foreach, etc.
I had to muddle the syntax a little bit though, so heres an example, taken from gwafa hazid, whom I added to the primitives to test with.
lord(creature[counter{0/0.1.Bribe}]|opponentbattlefield) cantattack
obviously the part we are worried about is the counter part, note that those are curly braces { } and periods . instead of parentheses ( ) and commas , this is so that it does not conflict with how targets are normally parsed, which it did before I changed those. Counters still work the same way everywhere else though, you only need to use { } and periods in target code.
Also, you can use counter{any} to specify that it should look for things with any kind of counter on them, not just specific ones, this is used by Kulrath Knight, for example.
I also consolidated most of the code used to parse counter specifications, as it seemed unnecessary duplicating it three times.
Anyway, aside from this major addition, I also added Gwafa Hazid, Profiteer; and Kulrath Knight to the primitives, as well as a test file for each to make sure it worked.
Hopefully y'all will find this patch useful.
Oh, and I should point out that it only works with one Counter in the target specification, i imagine if you put two in the same one then it would either overwrite the first with the second or merge them into some sort of hybrid counter monstrosity, either way, I wouldn't suggest it. "
Cards with vanishing are also codable now. Have a look at the comments for explanation.
daily_build.
"@movedTo" in combination with "autograveyard" WORKS!" Thanks to Abrasax!
Fixed 18 cards, 1 of them is Rancor. Now works 100%, so issue311 is fixed.
You find a list of all added and fixed cards in the first comment.
- Added remove/add counters as a cost, patch by Salmelo, thanks man!. See primitives/mtg.txt -> Thallid to see how it works
- added test for i286 by salmelo
- added basic display for counters (this needs improvement) by salmelo
Note: I replaced paragraphs (which Wagic can't display at the moment) with the sequence " -- ". If that's not desired, they can be easily replaced, but I think they improve readability. Previously, paragraphs where transcribed into slightly larger spaces, and I found that slightly confusing when reading the texts in-game.
Note: I checked all changes manually, so in the cases where the value *has* to be different for the card to work (e.g.Covetous Dragon), I left the values as they were. In these cases I added a comment to the card code which notes why the values need to be different, so that no one else breaks the card by "correcting" them.
Note 2: You may have noticed that I used a fixed sequence of lines for all cards. That was a byproduct of the file unification process, but I think it's also rather useful. Above the "text=" line are the lines that we need to code (abilities=, target=, auto= etc.). Below the "text=" line are the fixed values (mana=, type=, power= etc.) which we only need to touch if either the card gets errata'd, or we need to do some tricky coding (e.g. Covetous Dragon). So, in other words, everything below the "text=" line should be okay now in both files, and doesn't need to be checked when implementing or debugging a card.