It is currently 09 Nov 2025, 08:02
   
Text Size

Ability_Activated and custom input

Post MTG Forge Related Programming Questions Here

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

Ability_Activated and custom input

Postby slapshot5 » 14 Feb 2011, 18:36

Hi all,

Is it possible to use custom input for targeting using Ability_Activated?

I'm thinking Brass Squire. It's pretty easy to implement.
Code: Select all
Ability_Cost abCost = new Ability_Cost("T", cardName, true);
Ability_Activated ab = new Ability_Activated(card, abCost, ???);
What about the ???? If I use null, I can't use setBeforePayMana, and if I use Target, I'm limited to what that can provide.

Can I do custom input for targeting with a tap ability?

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

Re: Ability_Activated and custom input

Postby friarsol » 14 Feb 2011, 18:56

There isn't really a custom input available for Ability_Activated.

However, I think this is the cleanest way to do it.

Write an Ability_Activated and a Ability_Sub with it. The Ability_Activated would target an Equipment you control. The Ability_Sub would target a Creature you control. The parent would resolve the child. The child would check if both targets are still legal, then attach the parent's target to its target.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Ability_Activated and custom input

Postby slapshot5 » 14 Feb 2011, 19:30

Thanks. I'll give it a try.

-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 54 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 54 users online :: 0 registered, 0 hidden and 54 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 54 guests

Login Form