45 Commits

Author SHA1 Message Date
Vittorio Alfieri
fbcb1feb88 Fixed primitives, fixed "proliferate" target chooser, improved "cycled" and "discarded" triggers, added new keywords "pcycledcount" and "ocycledcount" to calculate how may cards have been cycled this turn from a specific player, added new menu choices to instantly select/deselect and confirm all the possible targets (in any zone) during the target selection of an ability (e.g. Proliferation ability can target a lot of permanents and players so using that menu choice all the targets will be instantly chosen and then the current player will be able to remove any of them or confirm the entire selection). 2021-10-13 17:39:48 +02:00
Vittorio Alfieri
a82636b099 Fixed "Jolrael, Mwonvuli Recluse", fixed "Corrosive Ooze", added new keyword "all(myeqp)" in order to target all the equipments attached to a creature (e.g. Corrosive Ooze). 2021-08-07 13:42:28 +02:00
valfieri
e67078355a Improved target chooser to allow a multiple selection for player, creature and planeswalkers, now it's possible to use target(player,creature,planeswalkers) as well as target(<variable>player,creature,planeswalkers) and so on. Added abilities for giving exiledeath and handdeath to instant and sorceries (the previous were not working fine), Added ability to identify the cards with Cycling ability as a target, Updated all primitives with cycling ability, fixed all primitives with choose any target ability, Added/fixed primitives from RIX set. 2020-12-18 19:04:51 +01:00
Anthony Calosa
0778b13e2b Totem Armor 2017-03-14 03:40:29 +08:00
Anthony Calosa
bef1f6d8b8 aura parent 2017-03-13 18:16:22 +08:00
Anthony Calosa
4da7f77089 Cleanup tabs 2016-07-07 13:25:36 +08:00
zethfoxster
6ee00c138c Pretty huge patch here(sorry old habits never die :( )
lots of changes, many bug fixes,
first
added auto=count(targetchooser)
and countedamount wparsed int
they work together for cards where it is difficult to get working without knowing in advance how many we had ie: exile blah creatures, for each creature you exiled do effect.
auto=count(creature|mybattlefield)
auto=moveto(exile)
auto=draw:countedamount
it takes into account token creatures, which our old methods did not.

second, added "freeze" which is a "frozen" that automatically taps your target for you, for use when nesting or whenever needed where it was difficult to nest the ability with tap included.

added devotion for "iroas"

added reveal:x and scry x
reveal contains optionone/optiononeend ; optiontwo/optiontwoend ; repeat; afterrevealed/afterrevealed end.

this ability has heavy use of targetListIsSet(<amount>) and upto:amount, you MUST be certain that all cards being revealed have an action that removes them from reveal either in the first, second, or 3rd ability.
there are over 300 examples in the new card code, the ability is VERY easy to understand.

scry contains automatic put on top, put on bottom, then scrycore/scrycoreend which is an ability to fire.
it also contains keywords, dontshow which is nested in scrycore, scry reveals, puts on top or bottom, then reveal AGAIN, and does an effect, dontshow eliminates the 2nd revealing.
is also contains "delayed" keyword, which delays the ability until AFTER the core fires.

added bestow. update rules mtg.txt!!!!
examples are in primitives, every bestow card was supported.

added a new lord based on varibles and restrictions
while(restriction{morbid})
while(varible:blah)
this simplifies and expands on this(, allowing you to even use while(cantarget together and check if a card is targetable by the variable. examples are in primitives

added token(by card name)
auto=token(Eldrazi Scion) 
will search primitives and card dats for this card and give it to you as a token.
valid card dat info is still required.

added variable delirium
added restriction madnessplayed to allow checking if the card was played with madness.

added restriction "geared" for checking if a card has equipment on it.

added abilities words
skulk

menace <--cant be blocked except by 2 or more, if you dont block it with 2 or more we automatically unassign the single blocker and the creature is considered not blocked.

nosolo <--cant attack alone

mustblock <---if you dont assign as a blocker, we assign automatically the first thing it can block legally.

changed iscolorless back to "colorless"

enjoy, cards coming soon, theyre coded but im debating on not alpha sorting, cards being added this patch 965 uniques.

there is a section of the commit which was just VS2016 normalizing line ends, sorry if it makes it a cluster mess.
2016-06-28 18:40:55 -04:00
wagic.the.homebrew@gmail.com
bd25b12fb2 Fix for issue 962 (Hexproof) by Dmitri 2013-09-15 02:57:29 +00:00
Xawotihs@gmail.com
26ab65860e Fixed a gazillion of warnings occuring when compiling Wagic with Clang with Werror. 2013-06-09 21:16:39 +00:00
omegablast2002@yahoo.com
ca3dc49d71 added basic card draw replacement,
auto=replacedraw choice damage:2

auto=replacedraw choice draw:2 noreplace

notice noreplace exempts the draw from sending a draw event. draw events and drawn events are seperate events.

added dredge and it's rules.

[card]
name=Dakmor Salvage
auto=tap
auto={t}:add{b}
dredge=dredge(2)
text=Dakmor Salvage enters the battlefield tapped. -- {T}: Add {B} to your mana pool. -- Dredge 2 (If you would draw a card, instead you may put exactly two cards from the top of your library into your graveyard. If you do, return this card from your graveyard to your hand. Otherwise, draw a card.)
type=Land
[/card]
2013-01-20 20:13:07 +00:00
omegablast2002@yahoo.com
0dbcd86b89 this commit adds AVRs new ability soulbond.
it requires an update to your mtg rules txt...
the coding is as follows

[card]
name=Arbor Elf
mana={g}
auto=soulbond 1/3
auto=soulbond {t}:add{g}
abilities=soulbond
type=Creature
subtype=Elf Druid
power=1
toughness=1
[/card]

auto=soulbond *any ability supported by wagic*
abilities=soulbond

the above arbor elf gives itself and its soulbond creature a 1/3 bonus and the ability to tap for green mana.
2012-07-16 14:59:46 +00:00
omegablast2002@yahoo.com
b705158e13 added "blockable" targetchooser, a targetchooser which shows the cards considered "blockable" by source.
corrected an error in ability$! parsing that prevents transforms to use it in newability[

added "block" keyword. and ability.
2012-04-02 13:32:50 +00:00
omegablast2002@yahoo.com
a497ef49c8 added support for doubling cube, recoded the curses to follow the rules better, with the exception of 1 which can not quite be supported
Curse of Oblivion moved back to unsupported.
added support for targeting a zone by targeting a player...
any time you have targeted a player, you can access items in thier zones by using 
targetedpersonsZONE
targetedpersonsbattlefield for example...
added "targetedplayer" as a targetchooser and who.
added "mycurses" targetchooser.
added "targetedcurses" word variable.
2012-03-15 06:18:08 +00:00
Xawotihs
9adb9d625d - reworked the testsuite and the rules (storyflow) to use the same game deserialization code, moved that code to the players and zone classes
- removed every references to the gameobserver singleton. This object can now be instantiated several times as it's needed for minmax. To be able to do that, I mostly added a reference to a gameobserver from any targetable object (cards, players, spells) and abilities.
2011-10-01 13:30:30 +00:00
omegablast2002@yahoo.com
2a0e6ac2d7 just init order fix. sorry about that! 2011-09-11 14:36:52 +00:00
omegablast2002@yahoo.com
1e0268eb07 added parents and children TargetChooser
ok this target chooser is set apart from the others becuase it focuses on relationship between cards instead of other forms of checking, also i made sure to add a method for deeper Targeting.
it is the same as any other target chooser when it comes to writeing the syntax and can be used in almost every way a normal one can.
here is what i mean by deeper targeting
this targetchooser allows you to denote a nested targetchooser.

target(children[targerchooser])
all(parents[targetchooser])

it is plural becuase i do allow maxtargeting to be denoted here. lets say you want to have a domain that lets you do the following
"2 of my target inhabitants get +1/+1 until end of turn"
you can do this...
auto={0}:target(<2>children) +1/+1 ueot
how about even more complex?
auto={0}:target(<2>children[elf[power=1]]) +1/+1

2 of my children that are elves with power equal to 1.
the same goes for parents, you can also lord( with this targetchooser.

if you want to say 
"the inhabitants of this domain gain flying"
auto=lord(children) flying

here are some example coding that you can play around with.

[card]
name=Forest
text=G
auto=lord(children[elf]) +3/+3
auto={0}:target(<2>children) +12/+12
type=Basic Land
subtype=Forest
[/card]

[card]
name=Tidal Kraken
abilities=unblockable
target=land|mybattlefield
auto=connect
auto={0}:target(parents) destroy
text=Tidal Kraken is unblockable.
mana={0}
type=Creature
subtype=Kraken
power=6
toughness=6
[/card]

[card]
name=Arbor Elf
target=<upto:3>land|mybattlefield
auto=connect
auto=foreach(parents[forest]) 1/1
mana={0}
type=creature
subtype=elf
power=1
toughness=1
[/card]
*above, arbor elf can target upto 3 domains...for each one you choose to connect him to that is a forest, arbor elf would gain 1/1..

so as you can see it is pretty indepth.

note: all test pass.
2011-09-10 23:23:40 +00:00
omegablast2002@yahoo.com
6399917d25 changes:
added abilities:
proliferate
ProliferateChooser:new targetchooser for cards with counter and poison counters "proliferation".

MenuAbility:new internal ability to create custom menus of abilities which can be activated in sequence one after another.

multikicker, syntax kicker=multi{b}
works with variable word "kicked", the amount of times it was kicked.

target=<number>tc,target=<upto:>tc,target=<anyamount>tc,target(<number>tc),target(<upto:>tc),target(<anynumber>tc);
multitarget is now supported with the exception of "devided any way you choose" which can not be supported becuase we allow detoggling of targeted cards with a "second" click....so you can not click the same card 2 times to add it to the targets list twice for example.
this is minor, as the bulk of multitarget is not "devided"
removed 's' parsing for multitarget, added a limit of 1000 to "unlimited" for easier handling; we currently can't handle activation of an ability on a 1000 cards very well on any platform(infact i don't suggest it)

Countershroud(counterstring), this MTGAbility allows you to denote that a card can not have counters of the type "counterstring" put on it.
"any" is for no counters allowed at all. this is a replacement effect. cards state that they can still be the targets of counter effects, however on resolve nothing is placed on them instead.

@counteradded(counterstring) from(target):,@counterremoved(counterstring) from(target):: these are triggers for cards which state "whenever you add a counter of "counterstring" to "target"; added counterEvents struct; 

other changes:
added support for ai handling of multitargeted spells.

changed a few of delete( into SAFE_DELETE(, safed up a couple areas where they did not seem safe to me;

added better handling of menus presented to ai, it will try to select the best based on eff returns.

added varible lastactioncontroller for ai use, it keeps it truely from ever tripping over itself and brings ai more inline with MTG rules.

converted TC into a protected member.
added "abilitybelongsto" string to tc, and set "owner" of the tc. a tc should never belong to "no one" it should always have a owner.
abilitybelongs to string is solely for easier debugging, i found it was a pain to never know what ability created a tc while i coded multitarget. the owner of the tc is the only one that should be using it, if an ability needs to declare the opponent as the owner (choose discard which is currently unsupported for example) this will allow us to better handle that situation by setting the tc owner in the ability which called it.

rewrote the logic of "checkonly" in ai choose targets, the only time it is "checkonly" is when it is trying to see if it had a target for a spell before it cast it, i now set this in the actual function call instead, the old method was far to error prone.

wrote logic for ai checking of menu objects presented to it,
ai will now make better choices when a menu is presented to it based on what it already knows. this changes it from it's old method of "just click the first option".

taught ai how to use multi-mana producers such as birds and duel lands by adding a method for it to find it's mana for a payment. it can effectively use cards like birds of paradise and sol ring(without locking up). It's primary method of pMana searching was maintain for performance(no need to deep search if we have it in pMana).

added a vector to actionlayer to store mana abilities for pMana. this provides us with a dramatic improvement when mana lords are present by reducing the amount of objects that need checking when ai checks pMana.
with 80 mana objects and a ton of lords one instance i checked went from 8000ish checks down to 80<===big difference.

added "tapped" green coloring(sorry i missed that!)...added red coloring to current actionLayers current action card (usually the source).

changed "type(" restrictions second amount from atoi into wparsedint for more flexiable coding.

add "&" parsing to CD targetchooser, removed "iscolorandcolor" variables and functions becuase they were a hack the real fix was this.
cretaure[dragon&black&blue] a creature that is a dragon, and black and also blue.

changed some of the ai computeactions and
removed unneeded gaurds in ai chooseblockers, they did more harm then good.
2011-09-01 20:03:26 +00:00
omegablast2002@yahoo.com
f88178f2cf refactored the typemin: cast restriction, there was a reported bug with it and while debugging it screamed refactor.
so i converted it from string comparisons and counting the battlefield..into targetchoosers with declarable operator.
simplified the code from the mess it was before into something alot easier to card code with.

example before:
mytypemin:less type(land),opponenttypemin:* type(land)
becomes
type(land|mybattlefield)~lessthan~type(land|opponentbattlefield)

the new syntax is:
type(targetchooser)~operator~number
type(targetchooser)~operator~type(targetchooser)
the operator are:
morethan
lessthan
equalto
2011-07-07 11:39:06 +00:00
wagic.the.homebrew
a84eb8dc22 -Fix for issue 583 (fireball crash)
-- converted an array into a vector to avoid weird edge cases
-- fixed bugs with array "backupTargets"
2011-05-26 12:27:44 +00:00
omegablast2002@yahoo.com
93d9347566 added "colors" to word variables
========================================
added a function to return the action element id by mtgcardinstance.
=======================================
refactored all 5 combat triggers to be handled in a single class, this change helps reduce the "bits and pieces" of trigger restrictions which some did support while others didnt, it also allows for easier editing and debugging if future code needs to be added to it.
refactored the parsing for the combat triggers also, so that a combat trigger can be built from a single object if it only contains "or"...amongst other reasons.
the new syntax is auto=@combat(blocking,attacking,turnlimited,once) source(TC) from(TC):effect...all the same words are still used, except they are now all included inside the combat(-----) this includes restrictions for the triggers. if a card still needs multiple triggers from some reason...it is still 100% allowed to have as many as you want, with whatever you want inside them...check updated primitive for examples.
the required sections are auto=@combat(atleast one trigger) source(TC):effect.

=========================================

moved the limitsperturn "limit:" from genericactivatedability up to its parent class activatedability, did this for the following reason
first rules correction, the previous method tracked uses on resolve, which is incorrect, it should count as the ability is fired and placed on the stack.
second, it keeps all the actiavted ability restrictions in the same place, this is the location we are checking summoning sickness, actived restrictions such as "myturnonly" ect. makes sense to handle it in the parent.
third, it allow any and all future activated abilities easy access to "limit:" if needed, it would only require adding a limit string to pass on construction to the child classes instead of recoding the same exact checks as genericactivated.
=======================================================
reworked "name(" so that it no longer is required to be used inside a "&&" ability, also it no longer will create a MTGAbility object with a false return. that was just dirty of me :/
enabled "name(" to replace the menutext of alternative cost. 
"other={cost} name(holy cow)"
will display "holy cow" instead of "pay alternative cost", this change is nice because we ended up using "other" cost for WAY more then originally planned...now we can label it exactly what it should say when you click it.
======================================================
added a subtype keyword for powertoughnessmodifier so that you can basically switch on non-static variables for it...lifetotal/lifetotal nonstatic...PT can now except all word variables as i added reparsing of the ints, had to maintain old methods as ai needs them to decide what to do with them.
======================================================
removed the following extremely redundant classes
both ABecomes classes---atransformer has become far superior to it, i kept the "becomes(" parsing tho, and it will act exactly as it use to, except now it has access to most of the subkeywords of transforms...it also now allows word variables. and excepts "forever" as a tag. added "newcolor" subkeyword to transforms to create the "becomes(" adding a color without removing colors effect. "becomes(" now returns a constructor for ATransformer that emulates becomes( exactly as it worked before.

both forevertransformer classes, the only difference between the 2 was one subkeyword, and "forever" did not return a "destroy()"...i recreated this in less then 4 lines and a bool. that was sloppy of me :( i guess we learn and improve.
============================================================================
i removed the parsing of card casting restriction from the first pass when cards load, instead of making it a cardprimitive object, i now simply pass the string through the card and build the restrictions when theyre actually needed and checked.
this change allowed for alot of clean up, removing enum and dependancy on cardprimitive, and combining both allowedAltCast and allowedtocast functions checks through a new function "parseCastRestrictions"...this change keeps all the cast resrictions in a single place, which makes it easier to debug or add if needed, and while i was at it, i enabled it so cards can now contain as many restrictions as you want *of the available ones* 
added "turn:" as a restriction to make it so "fourth turn" could actually be ANY turn you list, this allowed me to remove a dirty line of code which was checking if a card was o converted cost but had a suspend...lotus bloom...which can not be cast normally..for cards like this now you can use restriction=turn:200 or otherrestriction=turn:200....
=========================================================================
added Phyrexian Mana...svntax {p(r)} ....this will always be payable with 2 life, but if you have a red mana for this example, it will charge you the red mana instead...you can have any combination of P mana you want in any of the games manacost.
===================================================
reworked a bit of the ai logic i added, it now has true interrupting and can now correctly target for fizzles, Ai will go into full out counterspell wars with you now...
===================================================
added a ingame reward system with fancy flying text animations, they reward the player with actual credits, but are extremely hard to trigger off, theyre not meant to be something you see every 5 secs, but something that when you see them trigger you go "damn that was cool"
the triggers and effects are as follows
first the combo system:
you have to chain cast 5 or more card, without tapping or being interupted, tiny bonus for this..chain is broken as soon as you or your opponent tap something.
next combo level is
Abundant Resources - chain 10 or more spells same condition 
then
killer - chain 15 or more same condition
this will include a flying text render once a chain is successfully started (5+ cast)
this bonus can be triggered multiple times in a match

the next bonus is
+ //creatures entering play consecutively will allow you a chance 
+ //to gain a bonus for maintaining force sizes, it will trigger every 10th
+ //creature which enters play consecutively.
this is restarted every time a noncreature enters play.
the levels are as follows, 
Deadly Force Bonus! -10 creatures enter play consecutively
Extreme Infantry Bonus! - 10 creatures enter play consecutively and you maintain a force size of 20+
Malignant Conqueror Bonus! -10 creatures enter play consecutively and you maintain a force size of 40+
this can only be triggered once per level per match.

next bonus is given for having alot of a specific type come into play under your control during a match, this bonus only triggers once per match.
the levels are:
Toy Collector!
Beast Tamer!
Vampire King!
Lord of Swarms!
Master of Elements!
Zombie Apocalypse!
Sword And Shield!
Medic!
The Promenade!
Heavenly Host!
Teeth And Scales!
its pretty easy to figure out what each requires to trigger, teeth and scales for example is dragons, wurms, drakes, and snakes.
the final bonus is deal 100 damage from a single source in a single damage event, this one triggers only once per match.
============================================================
fixed the following bugs::::
regenerate was not working for non-creature regeneration ie:welding jar

ai would sometime get stuck in a infinate loop tho extremely rarely while deciding what to do, the cause 
if (clickstream.empty())
computeActions();
is NOT enough...ai should NEVER be computing actions (finding a card or ability to play) when it is NOT the active player..meaning, it does not have priority. 
g->currentlyActing() is the player that has priority. 
if (clickstream.empty() && g->currentlyActing() == this)...loop fixed :)

dynamicability had a couple weird results, from sources which dont have an amount to return, i now check this and if non, the amount is 0.

transformer will no longer add the same types a card already has..

removed an unneeded 
if (!activated) ....oris bug seems to be corrected with this change.

wrapped limitsperturn checks in a conditional to skip it if there is no limit string. 

added safer method to get the target of the combat trigger. the previous could potentially cause a crash if you interrupted the ability while the combat trigger was on the stack, it would do a call to "getnextopponent" and return a null pointer. i now send the opponent with the event. 

fixed a crash that would happen when a card did not have a type= line. having a type or subtype line is now optional. and highly recommended to avoid using "type=nothing"

moved a function call in buyback isreactingtoclick so that it checks if its in the hand before parsing the restrictions for it.

removed allowedtocast function calls from the alternative payment types, they are only supposed to check allowedtocast if it is something like "buyback" and kicker...not "you may pay this instead"....

corrected an issue with type: variable where it would add the amount depending on the activeplayer. to correct i added a method to call TargetZoneChooser::targetsZone( with a mSource...so that you can set the source card for the scan.

note: all test pass.
2011-04-12 20:54:34 +00:00
omegablast2002@yahoo.com
2f82f1888c couple things, first i goofed up in 2 spots, the equipment check for legality, yes shroud isnt a case, but it is also not a case of why you shouldnt remove it from a card which is illegal, so reworked it to find that the items i was looking to exclude( the protections) were all in a single spot :) yay to good programing!...so i pass a bool now with cantarget "withoutProtections" defaults to false so protections are always accounted for unless you specify not to include them, which is what ive done....now if only auras had a nice little spot to add such coding we can correct this rule on auras...
2nd, fixed a misunderstood line i added, i was aiming for the tc that triggered the event in trtargted....all tested passed, and i didn't manually test that change (SHAME ON ME!!!)...corrected it in the correct place now, where the event is sent.

3rd, trying to fix a broken alias class, this is a work in progress, i intend to fix this and then convert it to a keyword for draw replacement effects for 16.1(?) anyways, only thing ive left to figure out is telling it how to determine that the last stack ability is a "draw" ability. this class quit working ALONG time ago when the "addDraw" object was no longer used. the methods for card drawing changed and no one updated the alias class to use the new method, i imagine this is also what broke aladdins lamp originally(which the change of draw events and how card display is set up)
2011-04-05 16:03:19 +00:00
wagic.the.homebrew@gmail.com
8dd6856453 Erwan
- fixed issue 595 (MaxCast not working). Root cause was the stupidest typo ever in the code (maxCost instead of maxCast...)
- fixed an issue with Storm mentioned by zethfox (was counting only spells played by current player)
- Moved "max lands per turn" rule outside of the code (yay!) Please be sure to update your Rules folder!
2011-02-15 14:17:34 +00:00
techdragon.nguyen@gmail.com
e53c16f700 No code change just reformatting of header files.
finishing up my reformatting of the source from November/December following the guidelines that were posted.
some extra things I added:
   * Any empty virtual declarations were kept to one line.  
   * Enums were split up into separate lines to promote uniformity across all headers. ( each header file had a different style for enums)
2011-01-21 18:01:14 +00:00
wrenczes
d5f3e4cfea Enabled precompiled headers for the build. This cuts the win compile time in debug by at least half on my laptop; on the psp compile, it shaves it down by ~ 45 seconds. I only did a cursory inspection of what to add to PrecompiledHeader.h, there's probably more that we can throw in there for more incremental speed improvements.
Also fixed the project includes so that we don't need to always use the indirect include path, ie:
#include "../include/foo.h" -> #include "foo.h"

I'm don't know much about make files - if I busted the linux build, mea culpa, but I think we're okay on that front too.  For future reference, here's the most straightforward link on the topic of adding pch support to make files:

http://www.mercs-eng.com/~hulud/index.php?2008/06/13/6-writing-a-good-makefile-for-a-c-project
2010-10-24 05:55:24 +00:00
omegablast2002@yahoo.com
d13e8904b5 massive update, additions and changelog in first comment. 2010-10-18 10:46:36 +00:00
salmelo16
9cf4c7587b added ability to have triggered abilities target based on the event that triggered, bramblewood paragon, graft, etc.
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.
2010-04-03 23:50:39 +00:00
wagic.the.homebrew@gmail.com
11ed497ebb Erwan
-fix issue 209 (Clone loops AI)
2010-01-15 16:49:17 +00:00
wagic.the.homebrew@gmail.com
da07370243 Erwan
- (Finally) adding "must" abilities. Usage is as natural as possible, check Aven cloudchaser in 10E.
2010-01-06 14:22:41 +00:00
Psyyringe
5c3b3f1d03 Psyringe - added quantifiable target restrictions. Whenever you use square brackets [] to specify attributes of a target, you can use the operators <=, >= and = to specify quantities for power, toughness, and/or converted manacost. See added cards for examples.
Limitations:
- Operators for "greater than", "less than", "unequal" have not been implemented, but if a card actually needs them, you can use a preceding minus sign to negate a comparison. Example: -power=3 means "power not equal to 3", -toughness<=3 means "toughness>3".
- You can't use spaces when specifying such restrictions. Write "power<=3" instead of "power <= 3"
- You now need to use a space before the "<" and ">" commands that count the matches for lord(), foreach(), all() and aslongas(). So far we always did use spaces in front of them without actually needing to, now we need to.
- manacost restrictions don't take "X" costs into account. Example: Mistmeadow Skulkin (FUT) has protection from manacost>=3. Blaze has a converted manacost of 1, but when you cast it with an X of 2, then it actually has a converted manacost of 3 while on the stack, and Mistmeadow Skulkin would be protected from it, but currently it isn't.

Please review the code, I'll add a few remarks/questions of my own.
2009-12-26 01:50:33 +00:00
wagic.the.homebrew@gmail.com
ee3286ff2a Erwan
-Fix issue 206 (rain of filth)
2009-12-13 09:33:51 +00:00
wagic.the.homebrew@gmail.com
da9a82cff4 Erwan
- removed some unused code. Please review!
- Added protection from() auto keyword. It is still possible to use protection from [color] in abilities, but when it is not possible, please use protection from([target]) in auto=
2009-11-21 07:26:26 +00:00
wagic.the.homebrew@gmail.com
7f9d22e0aa Erwan
-fixed a memory leak
- Added P02 and PTK 
- New way to create tokens in the parser, much more flexible, see the Hive in RV. Tokens can now be written as other cards, with a rarity of "T". I suggest their id to be the negative value of the card that generates them when possible. Naming convention for images is the same as before: a negative id such as -1138 will need a [id]t.jpg image (1138t.jpg). Positive ids work as "normal" pictures
2009-11-18 13:14:08 +00:00
wagic.the.homebrew@gmail.com
9ca552093e Erwan
- Added "PreventAllCombatDamage" [from(...)] [to(...)] keyword. Please test it on a few cards before we "mass" use it. As a side effect, fixed issue 155 (ebony horse target).
2009-11-14 11:35:29 +00:00
wagic.the.homebrew@gmail.com
67755a4428 Erwan
- fix prowess of the fair
- add "other " keyword to all targets. ex: @movedTo(other elf|graveyard)
2009-09-14 14:07:30 +00:00
jean.chalard
3349f974f1 J :
* New interface.
* This breaks a lot of things. It is not feature-equivalent. It
  probably doesn't compile under windows and doesn't work on PSP.
* Damage is not resolved any more. This will have to be fixed.
* Blockers can't be ordered any more. This will have to be fixed.
* A lot of new art is included.
2009-08-22 05:59:43 +00:00
wagic.the.homebrew@gmail.com
76d386be06 Erwan
- fixed a bug with bottle gnomes (would give life to opponent even if you steal control)
- huge update for abilities life,draw,damage,deplete,discard in the parser. This breaks some cards (so we need to fix them) but allows more flexibility in the future. See my post on the forum
2009-07-25 14:57:27 +00:00
wagic.the.homebrew@gmail.com
a376e8110b Erwan
-added "this" as valid target (still needs some work)  see cathodion
- Added mythic rares in boosters
2009-07-20 03:35:26 +00:00
wagic.the.homebrew@gmail.com
ddc4636bf6 Erwan
-fixed "lord changes controller" bug
2009-07-05 04:49:21 +00:00
wagic.the.homebrew@gmail.com
ca3c2d30ab Erwan
- Magic 2010: Combat Damages don't go on the stack anymore
- Comp rules: "goes to graveyard" effects don't go on the stack anymore
- Regenerate "fixed" (untested)
- Basic "ReplacementEffect" mechanism for damage prevention. Can be extended to other replacement effects with some limits.
- TODO: Damages don't go on the stack, the abilities that create them do.
2009-06-23 14:22:00 +00:00
wagic.the.homebrew@gmail.com
b35195dddf Erwan
- Added crude possibility to search for the library (see Diabolic tutor)
2009-05-30 08:11:47 +00:00
wagic.the.homebrew@gmail.com
e7678522ee Erwan
- fixed a few memory leaks (but Wagic still crashes on the PSP after a few games :( )
2009-04-12 12:39:44 +00:00
jean.chalard
c97dd1f260 J :
* Remove ^M's.
* Re-indent automatically.
* Remove whitespace at the end of lines.
2008-11-12 13:45:42 +00:00
wagic.the.homebrew
01d2110e8d Erwan
- Added the possibility to narrow a spell/ability target according to color,tapped status, attacker/blocker, abilities...
- Changed the games phase system to become a phaseRing. This allows to add cards that have an impact on the phases, such as stasis
- Added a few cards
- Fixed a (windows) bug in gatherer tool
- Adding stdint.h for VC++ (see wikipedia->stdint.h)
- deleting the compiled PSP lib to avoid confusion. People who work from the sourcehave to compile the lib by themselves.
2008-11-09 04:28:03 +00:00
laurent.rabouin
4d798fe527 Added the todo.dat from ICE AGE
Added the Tap in the parser (works)
Removed the code from MTGAbility that could be added in the cards.dat and modified cards.dat
Tryed to add the shadow & landshome ability (does not work properly)
Added the maxtoughness in targechooser--> added the card Aegis from ICE AGE
2008-11-08 15:54:59 +00:00
wagic.the.homebrew
d45e3b101b 2008-11-02 09:50:16 +00:00