It is currently 08 Jul 2021, 00:17
   
Text Size

[fixed/closed]Ajani's Chosen

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

[fixed/closed]Ajani's Chosen

Postby ozks » 26 Sep 2013, 20:39

Describe the Bug:
you can't attach an enchantment aura to the token (Test with Dragon Fangs)

Which card did behave improperly ?
Ajani's Chosen

Which update are you using?(date,name)Which type(Duel,Gauntlet,Sealed Deck)
OoAv1

What exactly should be the correct behavior/interaction
able to attach an aura to the token

Are any other cards possibly affected by this bug ?
NA
Last edited by BAgate on 18 Jan 2014, 11:34, edited 4 times in total.
Reason: closed
User avatar
ozks
 
Posts: 279
Joined: 24 May 2012, 22:49
Has thanked: 107 times
Been thanked: 23 times

Re: Ajani's Chosen

Postby Gargaroz » 27 Sep 2013, 00:09

That part was not coded as it's currently impossible, sorry :(
----
- Current / medium term task: adjusting the code for making Misdirection and such usable
- Long term task: inserting all the good stuff I left out from the "Golden Years" mod
Gargaroz
Programmer
 
Posts: 7095
Joined: 06 Nov 2009, 11:11
Has thanked: 82 times
Been thanked: 593 times

Re: [uncodeable]Ajani's Chosen

Postby Korath » 27 Sep 2013, 11:05

Which part is impossible? I could see limiting it to auras that are enchanting creatures (and so we miss out on the handful of "Enchant permanent"s, "Enchant artifact"s, and "Enchant artifact or creature"s); but it seems pretty straightforward otherwise.
User avatar
Korath
DEVELOPER
 
Posts: 3522
Joined: 02 Jun 2013, 05:57
Has thanked: 491 times
Been thanked: 1037 times

Re: [uncodeable]Ajani's Chosen

Postby Gargaroz » 19 Oct 2013, 18:45

I mean, it's possible to move an enchantment from a target to another ? I always though it's impossible in Manalink. Also changing the targets of a spell already cast is possible ?
----
- Current / medium term task: adjusting the code for making Misdirection and such usable
- Long term task: inserting all the good stuff I left out from the "Golden Years" mod
Gargaroz
Programmer
 
Posts: 7095
Joined: 06 Nov 2009, 11:11
Has thanked: 82 times
Been thanked: 593 times

Re: [uncodeable]Ajani's Chosen

Postby Korath » 19 Oct 2013, 21:34

The exe only uses damage_target_player/card to see what an aura is attached to. The C-coded ones mostly (all?) duplicate that into targets[0], so that should be changed too if it's equal to the original damage_target_player/card.

The problem with changing a spell's targets isn't that they can't be changed to any arbitrary card; it's that there's no way to know whether it's a legal target. Moving auras doesn't target, so that's not an issue.
User avatar
Korath
DEVELOPER
 
Posts: 3522
Joined: 02 Jun 2013, 05:57
Has thanked: 491 times
Been thanked: 1037 times

Re: [uncodeable]Ajani's Chosen

Postby Gargaroz » 20 Oct 2013, 00:34

But simply changing damage_target_player/card does not automatically "moves" the aura from a permanent to another, the missing link (for me, at least) is knowing how to do that.
----
- Current / medium term task: adjusting the code for making Misdirection and such usable
- Long term task: inserting all the good stuff I left out from the "Golden Years" mod
Gargaroz
Programmer
 
Posts: 7095
Joined: 06 Nov 2009, 11:11
Has thanked: 82 times
Been thanked: 593 times

Re: [uncodeable]Ajani's Chosen

Postby Korath » 20 Oct 2013, 02:17

...it does for me.
move_auras.jpg
I'm testing with
Code: Select all
int card_elvish_mystic(int player, int card, event_t event){
    target_definition_t td_enchantment;
    default_target_definition(player, card, &td_enchantment, TYPE_ENCHANTMENT);

    target_definition_t td_creature;
    default_target_definition(player, card, &td_creature, TYPE_CREATURE);
    td_creature.illegal_abilities = 0;

    if (event == EVENT_CAN_ACTIVATE)
        return can_target(&td_enchantment);

    card_instance_t* instance = get_card_instance(player, card);
    if (event == EVENT_ACTIVATE){
        instance->number_of_targets = 0;
        return pick_target(&td_enchantment, "TARGET_ENCHANTMENT") && new_pick_target(&td_creature, "TARGET_CREATURE", 1, 1);
    }

    if (event == EVENT_RESOLVE_ACTIVATION){
        if (valid_target(&td_enchantment) && validate_target(player, card, &td_creature, 1)){
            card_instance_t* ench = get_card_instance(instance->targets[0].player, instance->targets[0].card);
            if (ench->targets[0].player == ench->damage_target_player && ench->targets[0].card == ench->damage_target_card){
                ench->targets[0].player = instance->targets[1].player;
                ench->targets[0].card = instance->targets[1].card;
            }
            ench->damage_target_player = instance->targets[1].player;
            ench->damage_target_card = instance->targets[1].card;
        } else {
            spell_fizzled = 1;
        }
    }

    return 0;
}
What are we doing different from each other? Are you trying to move the enchantment before it's done resolving?
User avatar
Korath
DEVELOPER
 
Posts: 3522
Joined: 02 Jun 2013, 05:57
Has thanked: 491 times
Been thanked: 1037 times

Re: [confirmed]Ajani's Chosen

Postby Gargaroz » 21 Oct 2013, 00:33

That's really strange, I remember Jatill tries to code something like this before and it didn't work. Well, it's just too great !
----
- Current / medium term task: adjusting the code for making Misdirection and such usable
- Long term task: inserting all the good stuff I left out from the "Golden Years" mod
Gargaroz
Programmer
 
Posts: 7095
Joined: 06 Nov 2009, 11:11
Has thanked: 82 times
Been thanked: 593 times

Re: [confirmed]Ajani's Chosen

Postby stassy » 22 Oct 2013, 08:42

So...fixed? Dragon serie card doable? Gift of Immortality doable? :P
stassy
Moderator
 
Posts: 5274
Joined: 25 Feb 2009, 07:06
Has thanked: 471 times
Been thanked: 337 times

Re: [confirmed]Ajani's Chosen

Postby Korath » 22 Oct 2013, 12:00

Not fixed yet, though we've been experimenting.

Gift of Immortality's a bit of a different case; the exe forces you to pick a target when putting an aura into play without casting it. (Which is why Replenish and Open the Vaults and so on work.) The current implementation makes everything but the right creature untargetable while putting it into play, which works, but is a bit ugly; it might work to set damage_target_player/card before the call to put_into_play(), as with Animate Dead.

Which dragon cards do you mean?
User avatar
Korath
DEVELOPER
 
Posts: 3522
Joined: 02 Jun 2013, 05:57
Has thanked: 491 times
Been thanked: 1037 times

Re: [confirmed]Ajani's Chosen

Postby stassy » 23 Oct 2013, 05:13

Dragon Scales, Dragon Shadow, etc...those should be affected by the bug too
stassy
Moderator
 
Posts: 5274
Joined: 25 Feb 2009, 07:06
Has thanked: 471 times
Been thanked: 337 times

Re: [confirmed]Ajani's Chosen

Postby Gargaroz » 28 Nov 2013, 16:36

Ability correctly implementated as 12bccbd
----
- Current / medium term task: adjusting the code for making Misdirection and such usable
- Long term task: inserting all the good stuff I left out from the "Golden Years" mod
Gargaroz
Programmer
 
Posts: 7095
Joined: 06 Nov 2009, 11:11
Has thanked: 82 times
Been thanked: 593 times


Return to Archived Reports

Who is online

Users browsing this forum: Bing [Bot] and 4 guests


Who is online

In total there are 5 users online :: 1 registered, 0 hidden and 4 guests (based on users active over the past 10 minutes)
Most users ever online was 1922 on 07 Jun 2021, 06:01

Users browsing this forum: Bing [Bot] and 4 guests

Login Form