It is currently 29 Oct 2025, 07:04
   
Text Size

Imprint

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, Agetian, friarsol, Blacksmith, KrazyTheFox, CCGHQ Admins

Imprint

Postby slapshot5 » 14 May 2011, 23:10

Hi all,

I've been looking at Imprint cards, especially Mimic Vat and Prototype Portal now that AF_Copy basically works. All of the Imprint stuff just looks like triggers and abilities for stuff that we have in AFs already. I'm wondering if the best way to handle Imprint is like this:

1. add an "Imprint$ True" check at the AbilityFactory.java level
2. If this is set, take the "Defined" or TargetCards from the given AF and set an ArrayList<Card> in the af.getHostCard() object
3. Make Imprinted accessible like:
*SVar:X:Imprinted$CardManaCost
*Defined$ Imprinted

That should handle most of the cards with Imprint I think.

If anyone's thought about this or has questions/comments/concerns, please post.

Thanks,
slapshot5
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

Re: Imprint

Postby friarsol » 14 May 2011, 23:25

Seems reasonable.

For Mimic Vat we would need a way to "unimprint" cards for those imprint abilities that aren't of the common variety.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Imprint

Postby slapshot5 » 14 May 2011, 23:47

Looks like I'm just going to parallel the Remember stuff. Save off in MagicStack.resolveStack() and check for Unimprint$ True right before saving any new stuff.
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

Re: Imprint

Postby friarsol » 14 May 2011, 23:49

Is there any way we can reuse the Remember stuff?
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Imprint

Postby slapshot5 » 15 May 2011, 00:03

I thought about that. But I don't want to get into a situation like Attached for Equipment and Auras, and not being able to tell which is which from scripting.

I can use the same function calls from MagicStack.resolveStack(), but I would use a separate data structure and it would be distinguishable in script as layed out in my original post.

I also think it should very specifically state "Imprint" in the AF params to be clear exactly what is happening.
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

Re: Imprint

Postby slapshot5 » 15 May 2011, 01:17

*sigh*

In general, this was a good idea, but it's a bit more complicated since "exile from hand" (i.e. ChangeZone hidden origin) don't use Target.

So, what I'll do for now is add manual calls to remember imprinted in those specific AFs.

Imprint cards are going to need careful testing, but I think we all already knew that.

-slapshot5
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

Re: Imprint

Postby Hellfish » 15 May 2011, 08:50

Heh, I was hoping to improve and expand Remembered to do exactly this. I understand your arguments,though, and the cards appear to work. :)

EDIT:Looking closer, a ruling on Prototype Portal states that the copy ability can't be activated if no card was imprinted. This is not currently the case. However, you'd think Soul Foundry would have the same ruling, but it does not. :?:
So now you're
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
User avatar
Hellfish
Programmer
 
Posts: 1297
Joined: 07 Jun 2009, 10:41
Location: South of the Pumphouse
Has thanked: 110 times
Been thanked: 169 times

Re: Imprint

Postby slapshot5 » 15 May 2011, 13:07

Hellfish wrote:EDIT:Looking closer, a ruling on Prototype Portal states that the copy ability can't be activated if no card was imprinted. This is not currently the case. However, you'd think Soul Foundry would have the same ruling, but it does not. :?:
Yeah, I read that when I was coding it. It's easy enough to add a SA_Restriction, but then I also saw Soul Foundry... I probably just need to go ahead and make the Restriction...

-slapshot5
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times


Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 7 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 7 users online :: 0 registered, 0 hidden and 7 guests (based on users active over the past 10 minutes)
Most users ever online was 9298 on 10 Oct 2025, 12:54

Users browsing this forum: No registered users and 7 guests

Login Form