Page 127 of 141

Re: Card Development Questions

PostPosted: 11 Jan 2014, 07:09
by torridus
Tested with 1.5.2 and 1.2.11 but unfortunately no.

Forge hasn't come up with any errors but none of these have worked:

SVar:X:Count$TypeInExile.Creature
SVar:X:Count$Valid Card.Exiled
SVar:X:Count$Valid Card.Exile
SVar:X:Count$Valid Card.inZoneExile

Re: Card Development Questions

PostPosted: 11 Jan 2014, 07:29
by moomarc
The count function you're looking for is SVar:X:Count$ValidExile Card where card can be any valid type string. You can check multiple zones with this function too by stringing zones together although I can't remember the exact syntax.

Edit: not in front of my PC and suddenly not certain of the syntax. It might have an underscore before the zone, so "Valid_Exile Card". Also, "TypeInExile Creature" with a space instead of point should work, but I think that method was deprecated recently.

Re: Card Development Questions

PostPosted: 11 Jan 2014, 07:59
by torridus
moomarc wrote:SVar:X:Count$ValidExile Card
This does the trick! Thank you.

Re: Card Development Questions

PostPosted: 29 Jan 2014, 17:05
by Max mtg
Which core type stands for a permanent, and which one does not?
Code: Select all
        Artifact(true),
        Creature(true),
        Enchantment(true),
        Instant(false),
        Land(true),
        Plane(false),
        Planeswalker(true),
        Scheme(false),
        Sorcery(false),
        Tribal(false),
        Vanguard(false),
        Phenomenon(false);
       
        public final boolean isPermanent;
       
        private CoreType(final boolean permanent) {
            isPermanent = permanent;
        }
Is this correct?

Re: Card Development Questions

PostPosted: 29 Jan 2014, 17:11
by friarsol
Max mtg wrote:Which core type stands for a permanent, and which one does not?
Code: Select all
        Artifact(true),
        Creature(true),
        Enchantment(true),
        Instant(false),
        Land(true),
        Plane(false),
        Planeswalker(true),
        Scheme(false),
        Sorcery(false),
        Tribal(false),
        Vanguard(false),
        Phenomenon(false);
       
        public final boolean isPermanent;
       
        private CoreType(final boolean permanent) {
            isPermanent = permanent;
        }
Is this correct?
Yep that's all correct, although these are referred to in the rules as "Card Types" not "Core Types", there are also "Supertypes" (Basic, Legendary etc), and "Subtypes" (Human, Aura, etc)

Re: Card Development Questions

PostPosted: 29 Jan 2014, 17:18
by Max mtg
friarsol wrote:Yep that's all correct, although these are referred to in the rules as "Card Types" not "Core Types", there are also "Supertypes" (Basic, Legendary etc), and "Subtypes" (Human, Aura, etc)
Thanks for confirmation.
I cannot name the enum CardType because that would lead to name clash. There's already a class named CardType that includes SuperType, CoreType and subType (the latter is alist of strings, the two former ones are EnumSets)

Re: Card Development Questions

PostPosted: 29 Jan 2014, 18:13
by Marek14
friarsol wrote:
Max mtg wrote:Which core type stands for a permanent, and which one does not?
Code: Select all
        Artifact(true),
        Creature(true),
        Enchantment(true),
        Instant(false),
        Land(true),
        Plane(false),
        Planeswalker(true),
        Scheme(false),
        Sorcery(false),
        Tribal(false),
        Vanguard(false),
        Phenomenon(false);
       
        public final boolean isPermanent;
       
        private CoreType(final boolean permanent) {
            isPermanent = permanent;
        }
Is this correct?
Yep that's all correct, although these are referred to in the rules as "Card Types" not "Core Types", there are also "Supertypes" (Basic, Legendary etc), and "Subtypes" (Human, Aura, etc)
And of course, "Subtypes" themselves are divided according to which card type (or types) they belong to.

Re: Card Development Questions

PostPosted: 04 Feb 2014, 12:51
by Max mtg
Please confirm someone that chages from r24656 are correct in terms of game rules.

I was sure that Chains of Mephisto did need a harcode.

Re: Card Development Questions

PostPosted: 04 Feb 2014, 13:20
by Sloth
Max mtg wrote:Please confirm someone that chages from r24656 are correct in terms of game rules.

I was sure that Chains of Mephisto did need a harcode.
I think the script looks fine. It's a normal replacement effect.

Do you see any case where it doesn't work?

Re: Card Development Questions

PostPosted: 04 Feb 2014, 13:57
by swordshine
It's a normal replacement effect.
Similar examples: You have four Blood Scriveners when you have no cards in hand and would draw a card, you will draw 5 cards and lose 4 life because each Blood Scrivener modifies the draw.

Re: Card Development Questions

PostPosted: 04 Feb 2014, 14:05
by Max mtg
Ok, it replaces "draw" with "discard, then draw" or "mill"
And that resulting draw in turn can be replaced by second Chains' static ability.
I'll test if the game does not enter an infinite loop here (i.e. first card won't replace draw caused by second card)

Re: Card Development Questions

PostPosted: 04 Feb 2014, 15:45
by friarsol
Max mtg wrote:Ok, it replaces "draw" with "discard, then draw" or "mill"
And that resulting draw in turn can be replaced by second Chains' static ability.
I'll test if the game does not enter an infinite loop here (i.e. first card won't replace draw caused by second card)
Once a replacement effect influences a single action, it shouldn't be able to influence that same action again. If that doesn't work in Forge, then having two Thought Reflection in play would cause an infinite loop too.

Re: Card Development Questions

PostPosted: 04 Feb 2014, 17:51
by Max mtg
I don't know why, but it works properly :)

Re: Card Development Questions

PostPosted: 04 Feb 2014, 17:55
by friarsol
Max mtg wrote:I don't know why, but it works properly :)
Lots of people working different levels of Magic on this software ;)

Re: Card Development Questions

PostPosted: 04 Feb 2014, 19:40
by Marek14
friarsol wrote:
Max mtg wrote:Ok, it replaces "draw" with "discard, then draw" or "mill"
And that resulting draw in turn can be replaced by second Chains' static ability.
I'll test if the game does not enter an infinite loop here (i.e. first card won't replace draw caused by second card)
Once a replacement effect influences a single action, it shouldn't be able to influence that same action again. If that doesn't work in Forge, then having two Thought Reflection in play would cause an infinite loop too.
What happens in these esoteric examples?

1. Lightning Bolt to Swans of Bryn Argoll, one draw replaced by Words of War, damage dealt to the Swans.
(I believe that the damage should not be replaced since it's still counts as the original action.)

2. Words of Wilding used to replace regular turn draw, Zameck Guildmage activated, Doubling Season on battlefield.
(I think that you'll get one token with one +1/+1 counter since turn draw is not an effect.)