Bug reports for Magarena 1.64
by ubeefx
Moderators: ubeefx, beholder, melvin, ShawnieBoy, Lodici, CCGHQ Admins
Re: Bug reports for Magarena 1.64
by sponeta » 22 Aug 2015, 06:24
Both Shurikens were unattached right after each other. The second one didn't do any damage, it wasn't targeted, and I didn't get control of it. The original equipped creature was still alive afterwards. It was like the first activation was looking for all cards named "Shuriken" and unattaching them.ShawnieBoy wrote:Not been able to reliably test this (The test engine doesn't allow setting up equipment or auras already attached to permanents, and the AI has other plans on how to use them).sponeta wrote:AI had attached two Shurikens to a creature. When the AI activated the ability given by Shuriken ability, both Shurikens were unattached at the same time.
Did you end up gaining control of both of them?
Strange that it doesn't occur with player activation.
The only thing I can think of is that if you didn't gain control of them, the AI targeted the equipped creature with one and killed it? (Hard to say without a log)
Re: Bug reports for Magarena 1.64
by sponeta » 22 Aug 2015, 06:24
When you pump Undead Leotau, it gets +1/+1 when it should get +1/-1.
Re: Bug reports for Magarena 1.64
by ShawnieBoy » 22 Aug 2015, 14:27
Thanks for the extra feedback - confuses matters further though...sponeta wrote:Both Shurikens were unattached right after each other. The second one didn't do any damage, it wasn't targeted, and I didn't get control of it. The original equipped creature was still alive afterwards. It was like the first activation was looking for all cards named "Shuriken" and unattaching them.
The unattaching, damage and changing control are all part of the same ability in the groovy. If one occurs, all should. If both Shuriken were triggering, I'd expect extra damage and both to change control as well.
The ability only references itself (the equipment) as the object to be unequipped, even though the ability is gained by the creature. It shouldn't be able to get confused about what itself is...
Something else is going on here as it's only affecting the AI as well.
-
ShawnieBoy - Programmer
- Posts: 601
- Joined: 02 Apr 2012, 22:42
- Location: UK
- Has thanked: 80 times
- Been thanked: 50 times
Re: Bug reports for Magarena 1.64
by melvin » 23 Aug 2015, 01:29
The problem is the ability holds a reference to the actual Shuriken object. This causes problem as the AI creates clones of the game for its own simulation. Abilities and triggers are suppose to be stateless thus they are NOT cloned in the AI's simulated game.
However, in this case, the activated ability is actually stateful because it holds a reference to the real Shuriken object. This means actions performed by the AI in its simulations could leak back to the real game. i.e. AI simulates activating the ability, which unattaches the real Shuriken.
Unfortunately there is no good way to fix it, since an activated ability generally cannot track both the permanent it is on and the permanent that generated it. The solution is to move the ability to the Shuriken itself instead of having Shuriken grant it to the equipped creature.
However, in this case, the activated ability is actually stateful because it holds a reference to the real Shuriken object. This means actions performed by the AI in its simulations could leak back to the real game. i.e. AI simulates activating the ability, which unattaches the real Shuriken.
Unfortunately there is no good way to fix it, since an activated ability generally cannot track both the permanent it is on and the permanent that generated it. The solution is to move the ability to the Shuriken itself instead of having Shuriken grant it to the equipped creature.
-
melvin - AI Programmer
- Posts: 1062
- Joined: 21 Mar 2010, 12:26
- Location: Singapore
- Has thanked: 36 times
- Been thanked: 459 times
Re: Bug reports for Magarena 1.64
by ShawnieBoy » 23 Aug 2015, 11:35
Thought this would be the final solution, not the best, but a good compromise. Thanks for looking into this.melvin wrote:The problem is the ability holds a reference to the actual Shuriken object. This causes problem as the AI creates clones of the game for its own simulation. Abilities and triggers are suppose to be stateless thus they are NOT cloned in the AI's simulated game.
However, in this case, the activated ability is actually stateful because it holds a reference to the real Shuriken object. This means actions performed by the AI in its simulations could leak back to the real game. i.e. AI simulates activating the ability, which unattaches the real Shuriken.
Unfortunately there is no good way to fix it, since an activated ability generally cannot track both the permanent it is on and the permanent that generated it. The solution is to move the ability to the Shuriken itself instead of having Shuriken grant it to the equipped creature.
-
ShawnieBoy - Programmer
- Posts: 601
- Joined: 02 Apr 2012, 22:42
- Location: UK
- Has thanked: 80 times
- Been thanked: 50 times
Re: Bug reports for Magarena 1.64
by ShawnieBoy » 26 Aug 2015, 11:27
Poor thing, he has his wings back - good find.kannikkiy wrote:Owl Familiar is missing flying.
-
ShawnieBoy - Programmer
- Posts: 601
- Joined: 02 Apr 2012, 22:42
- Location: UK
- Has thanked: 80 times
- Been thanked: 50 times
Re: Bug reports for Magarena 1.64
by melvin » 28 Aug 2015, 02:54
Good catch! Fixed in https://github.com/magarena/magarena/co ... e01be23371sponeta wrote:When you pump Undead Leotau, it gets +1/+1 when it should get +1/-1.
-
melvin - AI Programmer
- Posts: 1062
- Joined: 21 Mar 2010, 12:26
- Location: Singapore
- Has thanked: 36 times
- Been thanked: 459 times
Re: Bug reports for Magarena 1.64
by sponeta » 30 Aug 2015, 10:40
I had a bunch of creatures, AI had only Sporeback Troll. I played Slithering Shade, and AI decided to move a +1/+1 counter to it. I can't really think of any situation where this would make sense... except maybe Kulrath Knight, but I knew the AI's deck didn't have it.
Re: Bug reports for Magarena 1.64
by ShawnieBoy » 30 Aug 2015, 11:21
Would be really helpful if you have a game log of this - It's not likely to be a targeting issue by the AI, but it has been known to make strange plays when it doesn't see a way of winning (Which sounds like this case if you had a lot of creatures vs it's one).sponeta wrote:I had a bunch of creatures, AI had only Sporeback Troll. I played Slithering Shade, and AI decided to move a +1/+1 counter to it. I can't really think of any situation where this would make sense... except maybe Kulrath Knight, but I knew the AI's deck didn't have it.
(I sometimes think of this in real life game terms, the 'Kill me already' move )
-
ShawnieBoy - Programmer
- Posts: 601
- Joined: 02 Apr 2012, 22:42
- Location: UK
- Has thanked: 80 times
- Been thanked: 50 times
40 posts
• Page 3 of 3 • 1, 2, 3
Who is online
Users browsing this forum: No registered users and 40 guests