Page 1 of 1

Generic Manlands

PostPosted: 24 Jun 2010, 20:22
by friarsol
Hey guys,
So I found a bug when Manlands stopped being creatures, equipment didn't fall off them. (it would stay attached, but be invisible while not a creature)

Then when I went to see why that was. I was bothered by the fact that all of the manlands follow the exact same structure (I'm sure if I looked around enough that would be the case with lots of things) so I decided to pull the code out and generalize it. So I put the generalized code in CardFactoryUtil and added Dread Statuary. The only manland not implemented is Nantuko Monastery now.

And while the two functions were written for manlands they also are generic enough to work for things like Chimeric Idol.

I can submit this in, but I think I need to have permission to checkin. Lemme know what you think.

Code: Select all
public static void revertManland(Card c, String[] removeTypes, String[] removeKeywords)
public static void activateManland(Card c, int attack, int defense, String[] addTypes, String[] addKeywords, String cost)
Oh I also discovered a bug in unEquipAllCards where it will only unequip half of the equipped cards so I have a fix for that too.

Re: Generic Manlands

PostPosted: 24 Jun 2010, 20:29
by DennisBergkamp
Sure sounds good! PM me your email address (has to be associated with a google account), and I'll give you permission to commit stuff.