Page 1 of 1

[bug] Legends can be played repeatedly

PostPosted: 13 Feb 2011, 16:45
by Julgot2
I've discovered a bug in JPortal 1.2a:
Legendary Cards are not supposed to be in play more than once. I'm not familiar with the current ruling on what happens if a player plays the same Legend card a second time, but afaik the one already in play should then be buried.
However, I've caught the AI player playing a Legend Card twice, the program did not stop that.

Re: [bug] Legends can be played repeatedly

PostPosted: 14 Feb 2011, 08:39
by Malban
Yup.

I now. I already posted that in
thread: http://www.slightlymagic.net/forum/viewtopic.php?f=80&t=3926

As of now it is a feature not a Bug :-)!

But in one of these days I will correct it.

Regards...

Malban

Re: [bug] Legends can be played repeatedly

PostPosted: 08 Apr 2011, 14:42
by Malban
Hiho,

I had to do something else but AI - as told my had is spinning from thinking around all those corners.

I just had some thoughts about legendaries :-)!
In the next release I will make it configurative - as told. But you can have legendary ruling as of now if your want.

Copy and paste the code below to the game.
Goto Menu "AI", chose Item "Configure Card Templates", chose in the ComboBox Type "Legendary Creatures", chose in the ComboBox Situation Key "CARD_PLAYED", copy the below code and press "Save Template" - and legendary Creatures will kill each other :-)!

Well - The AI doesn´t know about it... but you do!
Code: Select all
      D.addLog("Legendary Ruling detected!",3);
      // no lets check if there is another of this kind in any battlefield!
      boolean foundOne = false;      

      CardList myField = match.getBattlefield(player);
      Card otherCard = myField.getCardID(card.getId());
      while (otherCard != null)
      {
         match.moveCardFromBattlefieldToGraveyard(player, otherCard);
         foundOne = true;
         myField = match.getBattlefield(player);
         otherCard = myField.getCardID(card.getId());
      }

      CardList otherField = match.getBattlefield(opponent);
      otherCard = otherField.getCardID(card.getId());
      while (otherCard != null)
      {
         match.moveCardFromBattlefieldToGraveyard(opponent, otherCard);
         foundOne = true;
         otherField = match.getBattlefield(opponent);
         otherCard = otherField.getCardID(card.getId());
      }

      if (foundOne)
      {
         // remove card - and dont play it out!
         match.moveCardFromHandToGraveyard(player, card);
         bRet = true;
         return;
      }

Regards

Malban