It is currently 19 Apr 2024, 00:31
   
Text Size

[confirmed]Ashnod's Altar v. animated Bottle of Suleiman

Report wrong Card behavior to get it fixed.
PLEASE ADD SAVEGAMES TO YOUR TOPIC !

Moderators: BAgate, drool66, Aswan jaguar, gmzombie, stassy, CCGHQ Admins

[confirmed]Ashnod's Altar v. animated Bottle of Suleiman

Postby Korath » 11 Sep 2020, 22:03

Describe the Bug:
Bottle of Suleiman enchanted by Animate Artifact can be activated when you control no other creatures or mana sources except an Ashnod's Altar. (Click on the Bottle first.)

Which card behaved improperly?
Don't blame the cards, it's not their fault.

Which update are you using? (date, name)Which type? (duel, gauntlet, sealed deck)
0dc14d10d - (master) Merge branch 'manalink/master_sep2020'

What exactly should be the correct behavior/interaction?
You can sacrifice the Bottle to pay for its own ability, or the Ashnod's Altar's ability, but not both.

Ideally, the Bottle's title shouldn't even turn yellow. It would be acceptable, but still wrong, for the activation to start but cancel itself after you sac the Bottle for mana, leaving you with two mana in your pool and no coin flip, damage, or Djinn.

Are any other cards possibly affected by this bug?
Yes, indeedy. (I first saw it with the AI trying to sacrifice a Food to Gilded Goose to help pay for sacrificing the Food to gain life.) I only picked this combination because all three are original Microprose cards, and it looks like the original game will exhibit this bug too. (I haven't tested that, since I don't have an unmodified install handy; I doubt anyone else does either. It's at least conceivable someone has an unmodified Shandalar around and is bored enough to try it out, I guess.) This search plus Manalink's approximations of Rain of Filth and Basal Sliver should be comprehensive for the rarer half of this bug: a mana ability with "sacrifice <something else>" in its cost.

It's also possible this can happen the other way, too: something like sac a Black Lotus to get mana to pay for a " {3}, Sacrifice an artifact: ..." ability.

Tangentially-related aside: Priest of Yawgmoth and Bottle of Suleiman are both original cards, too, but they won't have this bug solely because the original Priest implementation doesn't declare any mana available at all. Neither does the Manalink version of the Priest, though I see now, for the first time, a commented plea in its source for me to make it do so, which has been there since May 2014. Sigh.
  1. Call itself with event=EVENT_CAN_ACTIVATE to see if it can activate at all. If so,
  2. Find the sacrificeable artifact its controller controls with the highest converted mana cost. (So not an artifact creature with an Assault Suit attached, or artifact creature at all if there's an Angel of Jubilation on the bf, or an Everlasting Lich that's been turned into an artifact. There should be a function to exclude those already.)
  3. Declare that much black mana available.
  4. Related to the first half of this bug, don't double-count the Priest for a spell with convoke (or an artifactified Priest for a spell with improvise). I'm still not sure whether it's better to deal with this, or part of this, in the mana source cards' functions.
  5. Try to account for non-zero-cmc artifacts that can sac themselves for mana, like Composite Golem or Implements of Sacrifice, if you're crazy enough.
Attachments
ashnods-altar-v-bottle-of-suleiman.jpg
Last edited by Aswan jaguar on 12 Sep 2020, 09:40, edited 1 time in total.
Reason: confirmed
User avatar
Korath
DEVELOPER
 
Posts: 3707
Joined: 02 Jun 2013, 05:57
Has thanked: 496 times
Been thanked: 1106 times

Re: Ashnod's Altar v. animated Bottle of Suleiman

Postby Aswan jaguar » 12 Sep 2020, 09:39

Confirmed and confirmed bugged also for original game.
---
Trying to squash some bugs and playtesting.
User avatar
Aswan jaguar
Super Tester Elite
 
Posts: 8078
Joined: 13 May 2010, 12:17
Has thanked: 730 times
Been thanked: 458 times

Re: [confirmed]Ashnod's Altar v. animated Bottle of Suleiman

Postby drool66 » 20 Oct 2020, 04:20

Tangentially-related aside: Priest of Yawgmoth and Bottle of Suleiman are both original cards, too, but they won't have this bug solely because the original Priest implementation doesn't declare any mana available at all. Neither does the Manalink version of the Priest, though I see now, for the first time, a commented plea in its source for me to make it do so, which has been there since May 2014. Sigh.
Call itself with event=EVENT_CAN_ACTIVATE to see if it can activate at all. If so,
Find the sacrificeable artifact its controller controls with the highest converted mana cost. (So not an artifact creature with an Assault Suit attached, or artifact creature at all if there's an Angel of Jubilation on the bf, or an Everlasting Lich that's been turned into an artifact. There should be a function to exclude those already.)
Declare that much black mana available.
Related to the first half of this bug, don't double-count the Priest for a spell with convoke (or an artifactified Priest for a spell with improvise). I'm still not sure whether it's better to deal with this, or part of this, in the mana source cards' functions.
Try to account for non-zero-cmc artifacts that can sac themselves for mana, like Composite Golem or Implements of Sacrifice, if you're crazy enough.
Well, 1-3 looks like this I think:
Code: Select all
   if( event == EVENT_COUNT_MANA )
      if (affect_me(player, card) && CAN_TAP_FOR_MANA(player, card) && !is_sick(player, card)){
         int c, result = 0;
         for (c = 0; c < active_cards_count[player]; ++c){
            if (in_play(player, c) && is_what(player, c, TYPE_ARTIFACT) && can_sacrifice_this_as_cost(player, c)){
               int cmc = get_cmc(player, c);
               if (cmc > result){
                  result = cmc;
               }
            }
         }
         declare_mana_available(player, COLOR_BLACK, result);
      }
User avatar
drool66
Programmer
 
Posts: 1163
Joined: 25 Nov 2010, 22:38
Has thanked: 186 times
Been thanked: 267 times

Re: [confirmed]Ashnod's Altar v. animated Bottle of Suleiman

Postby drool66 » 22 Dec 2020, 06:26

Basic implementation of 4 in 9e890f2
User avatar
drool66
Programmer
 
Posts: 1163
Joined: 25 Nov 2010, 22:38
Has thanked: 186 times
Been thanked: 267 times


Return to Bug Reports

Who is online

Users browsing this forum: No registered users and 52 guests


Who is online

In total there are 52 users online :: 0 registered, 0 hidden and 52 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 52 guests

Login Form