Commit Graph

3727 Commits

Author SHA1 Message Date
omegablast2002@yahoo.com
fea034281d added support for suspend x...
suspend(0)={g}{x}

cards with x in thier suspend cards will suspend for x turns...x can not be 0 as per mtg rules.
2011-09-27 01:47:08 +00:00
solo81@web.de
29e9cad492 Fixed Tetravite token. 2011-09-25 21:15:45 +00:00
solo81@web.de
28dbb4de96 Fixed One-Eyed Scarecrow. 2011-09-25 21:01:31 +00:00
omegablast2002@yahoo.com
3417799eda removed the phase restrictions enum from activatedability, it inherited this from MTGAbility, the only difference is actiavted ability had opponentturnonly listed as 69, so in some cases it would be 60 and sometimes 69, it will now always be 60 following the enum in mtgability. 2011-09-25 17:02:39 +00:00
omegablast2002@yahoo.com
e2829102aa corrected the test, it was missing choice 0 to gain the life. 2011-09-25 16:57:35 +00:00
omegablast2002@yahoo.com
e117cf82c9 just moving parserestrictions under the parsecastrestrictions...so they are together rather then an entire page apart :) no code change, it just bugged me :P 2011-09-25 13:51:33 +00:00
omegablast2002@yahoo.com
3a2264febb just changing some comments in svn... 2011-09-25 13:41:12 +00:00
omegablast2002@yahoo.com
e8ea5a28d7 added a space to the parsing of who in @next and @each....this space always existed in the coding we use however i am now making it required, the reason is that now we have tool which can include tc's and "s" was finding opponent and my in the tcs effecting the triggeratphase it created. this should correct that issue. 2011-09-25 13:38:15 +00:00
omegablast2002@yahoo.com
96cbe18be0 taught ai basic extracost targeting...by basic i mean its not going to choose a token creature over its 20/20 flyer for the target of an extracost...it will target whatever it can for the cost. but atleast it can handle extra cost which are targeted now, rather then ignore them completely.
also removed a peice of aiplayer::render, that was moved into aiplayerbaka.....
2011-09-24 18:42:37 +00:00
solo81@web.de
404137b144 Added two tests for Morbid. 2011-09-24 13:34:08 +00:00
solo81@web.de
df3b2a7fa6 Corrected several card ids from ISD.
Corrected Grimgrins cost and text.
2011-09-24 12:27:44 +00:00
solo81@web.de
9938e1a57c ISDs _card.dat was missing the "_". Now it works. 2011-09-23 20:11:57 +00:00
omegablast2002@yahoo.com
f04a0dd338 better handling of cards with restrictions for ai. if we can't play it, then don't make it nextcardtoplay. 2011-09-23 19:48:17 +00:00
solo81@web.de
7ba6c8e85d Added Innistrad (ISD). 200 cards out of 264 were codable for now. 2011-09-23 19:12:26 +00:00
omegablast2002@yahoo.com
2bb651c5b4 fixed a crash in "white" rendering when you don't actually have the graphic for "white". 2011-09-23 19:05:10 +00:00
wagic.the.homebrew
eb13d9a0f9 - Mark "equipment" abilities as good for AI (used for MotD) 2011-09-23 10:54:01 +00:00
wagic.the.homebrew
fe88b747c0 - fix for ACounterTracker (this fixes the ability - it wasn't working before - as well as the memory leak)
- fix "release" build in VC++
- Let AI play creatures with ACounterTracker by making that ability a "positive" one (used for MotD)
2011-09-23 10:24:20 +00:00
wagic.the.homebrew
c633dc805f - Adding "connected cards" color rendering
- Made "booster" check mod-dependent in test suite
2011-09-23 07:24:24 +00:00
wagic.the.homebrew
0b66caebf2 Fix PSP compilation issue I introduced in my previous change 2011-09-23 00:15:32 +00:00
solo81@web.de
83cdf5c151 1) Removed all "{0}" from the upcost bracket of all cards with Echo. Once it was needed to work around a bug, but now that the bug is fixed.
2) Updated all {X}-spells with x targets. They are using "prex" instead of "x" now. Their code is now completely   
following the official rules.

3) Changed the code of most cards which search your library for a land card and put it onto the battlefield tapped.
They are using "and((tap))" now. More cards will be changed to that in upcoming revisions.

4) Added 2 tests to save "prex".
2011-09-22 23:34:11 +00:00
wagic.the.homebrew
f649fee465 - Minor refactor of a few files: removed some unnecessary calls, etc... 2011-09-22 10:07:05 +00:00
wagic.the.homebrew
ee4c7e23bd - fixed memory leaks introduced in previous revision
- removed incorrect casts of MTGCardInstance into Spell objects.
- AI Test system now allows you to put decks in ai/bakaA and ai/bakaB instead of ai/baka. This allows to let AIPlayerBaka and AIPlayerBakaB play with specific decks
- Test suite speed improvement. Improved the card name cache. Test suite now runs in 850 seconds instead of 950 on my machine.
- minor code cleanup
2011-09-22 04:43:05 +00:00
omegablast2002@yahoo.com
997b154d46 volcanic eruption updated to use prex 2011-09-21 20:28:01 +00:00
omegablast2002@yahoo.com
4419ed4637 changed some logic for getting the pre x without shellcasting(?) spell...the variable word "prex" now returns the difference between the cards cost and the curentmanapool...giving us the value of pre x.some cards might need updating, doc can confirm it.... 2011-09-21 20:27:29 +00:00
wagic.the.homebrew
15f0143a8f AIPlayer minor tweaks:
- In order to clarify getEfficiency, started creating "getEfficiency" functions specific to each type of ability (see example with Damager). This won't reduce the file size but should make things bit clearer
- Minor cleanup of getEfficiency
- bug fixes in getEfficiency
2011-09-21 15:10:06 +00:00
omegablast2002@yahoo.com
11095f3339 added new functionality to AAMover...
you can now do 
moveto(targetzone) and((ability)) 
moveto(mybatlefield) and((transforms((zombie,black)) forever))
2011-09-21 14:06:32 +00:00
omegablast2002@yahoo.com
ab7eb1b93e fixed an error in my last commit. 2011-09-21 12:37:44 +00:00
omegablast2002@yahoo.com
4dbe69dacf fixed ai mana finding which broke in previous ai changes(maybe during the split or fixing the memleak) 2011-09-21 12:12:34 +00:00
omegablast2002@yahoo.com
807e818e92 add the manapool at the end of gotpayments, only once. otherwise we get false amounts. 2011-09-21 11:07:41 +00:00
wagic.the.homebrew
e9ce574bca - Fix a memory leak in AI "payTheManaCost"
- Minor fixes in AI code
- Attempt at preventing the AI from interrupting itself while it's selecting targets. I don't know why this happens, and my fix didn't work. I believe it shouldn't be possible to interrupt when there is an active targetChooser, please let me know if this is an incorrect assumption.
2011-09-21 03:54:47 +00:00
omegablast2002@yahoo.com
206f3b4d3f fixed a crash that happens in thisforeach when the matches is a negitive value. 2011-09-20 17:03:31 +00:00
wagic.the.homebrew
44d9951246 Adding a system to compare two AI implementations (AIPlayerBaka and AIPlayerBakaB). This can be used to make sure a change to the AI is not making the AI weaker, for example. 2011-09-20 11:32:24 +00:00
wagic.the.homebrew
4c45e971c6 Fix missing file (AIPlayerBakaB) 2011-09-20 03:58:12 +00:00
omegablast2002@yahoo.com
e3e0233b8a changed a couple wParsed ints to assign the spell or NULL rather then relying in card to cast it as NULL. 2011-09-20 03:13:52 +00:00
wagic.the.homebrew
fbfac78b09 - Split AIPlayer and AIPlayerBaka in 2 files. Moved all "AI" specific code into AIPlayerBaka, as much as possible.
-- This is a copy/paste and shouldn't have any impact on the logic. I just moved some functions from AIPlayer to AIPlayerBaka
- Added back the possibility to select a different Resource folder with file Res.txt
- Fix a crash when a token id does not exist
2011-09-20 03:06:06 +00:00
omegablast2002@yahoo.com
839d197835 fixed the memleak i introduced. 2011-09-19 20:31:36 +00:00
Xawotihs
bb65d2dc12 - various compilations fixes for Symbian
- small cleanups of the TestSuite and Player classes
2011-09-19 19:49:45 +00:00
omegablast2002@yahoo.com
180462f73c bug fix for an issue with multitarget, after a multitarget ability resolves the first time, i never set the tc->done back to false, so the first card clicked will think it is done every time after the first.
setting tc->done to false after targetability resolve.
2011-09-19 11:32:11 +00:00
omegablast2002@yahoo.com
e0aa60070c ifthen targeting tweak... 2011-09-18 19:35:00 +00:00
guzhenjie1@gmail.com
5abc1293ce Corrected Crumbling Colossus. 2011-09-18 15:52:44 +00:00
omegablast2002@yahoo.com
c0ab80a1bc fixed a bug in targetchoosing where a player would get stuck in a targetchooser under certain situations as follows:
opponent play an ability, player interupts and clicks a card with TargetChooser which has no valid targets; player then tries to cancel targetchooser, instead the stack is displayed again, player is then locked in a TargetChooser unable to click other cards.

originally i was going to do it in the reactToClick however, after thinking about it, it made no sense to me that a targetchooser would be set and a cardwaitingfortargets would be set if you know ahead of time that no valid targets existed.

now when clicking cards which have TargetChoosers and no valid targets, no tc is set, and no cardiswaitingfortargets; instead return 0.
2011-09-18 10:34:40 +00:00
omegablast2002@yahoo.com
2b8d174bfa Reveillark updated 2011-09-18 06:58:29 +00:00
omegablast2002@yahoo.com
4ab6dfd3da extended countertrack and teach( to creatures for use with countertracking...isolated equipment rule that states it can't equip a card it can't target in testDestroy(we want the equipments to stay on a creature even after it's hands are full :)
I'll take a stab at coding the current cards for the mod this evening.
2011-09-17 23:27:00 +00:00
Xawotihs
c5203a9caf Touch/mouse support for storyflow. 2011-09-17 21:27:36 +00:00
wagic.the.homebrew
c96d2fea55 Fix for issue 734 (creating profile on a fresh install is completely broken.) 2011-09-17 08:42:13 +00:00
omegablast2002@yahoo.com
a6c458d0cb ifthen ability sometimes wasn't grabbing the right target, i now pass it through MTGAbility creations target.
also, i see now why targeted counter cost were left broken for so long. i think this way fixes it in all cases. what a pain.
2011-09-15 11:50:04 +00:00
omegablast2002@yahoo.com
d04b4eca38 ai bug fixes, minor refactor of phaseaction/phaseactionmulti/upcost/upcostmulti, counter cost was safed wrong, sorry!, and fixed parsing of upcost..it was chopping the last bracket of the cost when used for things like echo, it required us to add {0} to those cost...that is no longer required. 2011-09-14 20:35:04 +00:00
omegablast2002@yahoo.com
9c9ce69259 safing up countercost related items, some possible crashes were found now that counter cost can be targeted. they should have really been there from the start. 2011-09-14 12:20:46 +00:00
omegablast2002@yahoo.com
5ece26d49a psp comp fix... 2011-09-14 12:07:33 +00:00
omegablast2002@yahoo.com
6ea7e00803 added countertrack(counterstring) MTGAbility
what this does currently is remove a counter of the type counterstring and when the ability is destroyed it puts the counter back for us.
meant for weapons used as follows.
auto=teach(creature) countertrack(0/0,1,hand)

when the creature is equipped with this weapon it will remove a hand counter from the creature, when you remove the weapon, or the weapon is destroyed or whatever...it will put a hand counter back on the creature.

added dualwielding thisdescriptor...
auto=this(dualwielding) 2/2
auto=this(dualwielding) firststrike

enabled "restriction{" on phasebased triggers @next and @each...

i will work more on countertrack to extend it to domains if it currently isnt possible to use it in this case(haven't tested it on domains)....
2011-09-13 14:33:13 +00:00