It is currently 19 Apr 2024, 18:41
   
Text Size

Talk about new cards here

Moderator: CCGHQ Admins

Re: Talk about new cards here

Postby thefiremind » 16 Aug 2013, 18:04

You can see it with any targetted spell: you don't see the lands tapping until you chose the targets, right? :wink:

EDIT: Just to be as clear as I can...
step 1 | Open
Image
step 2 | Open
Image
< Former DotP 2012/2013/2014 modder >
Currently busy with life...
User avatar
thefiremind
Programmer
 
Posts: 3515
Joined: 07 Nov 2011, 10:55
Has thanked: 118 times
Been thanked: 721 times

Re: Talk about new cards here

Postby gorem2k » 16 Aug 2013, 21:36

thefiremind wrote:You can see it with any targetted spell: you don't see the lands tapping until you chose the targets, right? :wink:

EDIT: Just to be as clear as I can...
step 1 | Open
Image
step 2 | Open
Image
Good. I'm not in the mood for that explanation right now. but if you play real with me and you ask me what I will target with -X, and then I say your Raging Goblin. and then I have not yet removed counters and I say sorry I choose your Goblin Warchief instead (counters are still on Chandra) and I say it's a Call, (remove counters , deal damage) it will be fine. but in game.. I choose this.. click OK. ooops too late, can't go back! nothing in the cost says "Choose a target first, then pay -X" when I activate Goblin Fireslinger I get prompted for which player, I can say "cancel" and then the goblin dont activate. this is how it should be with her.

better yet, Grim Lavamancer, you pick one player, fine, you can cancel but no you pick one, then you get asked to exile cards, fine, you can choose them, but hey I changed my mind, I click cancel, voilà! nothing happen until the final condition is met.

and please, I never talked about lands tapping in my message. I have a fair amount of gameplay to know how a card should act
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Talk about new cards here

Postby thefiremind » 16 Aug 2013, 22:14

OK, there's a misunderstanding going on... let's clear it up. We are talking about 2 unrelated things happening with your card:
  1. You are asked to choose the targets before paying the cost.
  2. You can't undo during the numerical choice.
From what you said before, I understood that you considered both things to be wrong, so I answered that #1 isn't wrong, this has nothing to do with #2, though. About #2, yes, I agree that it's wrong, or to say it differently, it's not coherent with the DotP mechanics, but if the developers didn't include the cancel button in the numerical choice, there's nothing we can do about it.

The solution you found about making nothing happen if you select 0 seems good to me, but you should check that the AI won't be caught in an infinite loop trying to activate the ability for 0 for an infinite number of times. If that happens, I'd suggest to add another condition: make nothing happen when selecting 0 and EffectController():IsAI() == false. This way, if the AI ever tries to activate the ability for 0 (maybe not in the actual game but during evaluation) it will find the ability doing nothing and shutting down Chandra for that turn.
< Former DotP 2012/2013/2014 modder >
Currently busy with life...
User avatar
thefiremind
Programmer
 
Posts: 3515
Joined: 07 Nov 2011, 10:55
Has thanked: 118 times
Been thanked: 721 times

Re: Talk about new cards here

Postby gorem2k » 16 Aug 2013, 22:30

thefiremind wrote:OK, there's a misunderstanding going on... let's clear it up. We are talking about 2 unrelated things happening with your card:
  1. You are asked to choose the targets before paying the cost.
  2. You can't undo during the numerical choice.
From what you said before, I understood that you considered both things to be wrong, so I answered that #1 isn't wrong, this has nothing to do with #2, though. About #2, yes, I agree that it's wrong, or to say it differently, it's not coherent with the DotP mechanics, but if the developers didn't include the cancel button in the numerical choice, there's nothing we can do about it.

The solution you found about making nothing happen if you select 0 seems good to me, but you should check that the AI won't be caught in an infinite loop trying to activate the ability for 0 for an infinite number of times. If that happens, I'd suggest to add another condition: make nothing happen when selecting 0 and EffectController():IsAI() == false. This way, if the AI ever tries to activate the ability for 0 (maybe not in the actual game but during evaluation) it will find the ability doing nothing and shutting down Chandra for that turn.
ok. I thought the code spoke to itself too. I will add IsAI() for sure. thanks
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Talk about new cards here

Postby cristianarodri » 30 Oct 2013, 14:07

Hi All, I'm new in DOTP programming and after some successful test with easy cards, I've tried to move forward and code Saproling Burst.
I can code the counters and the token generation, but the P/T of them, I just can't control it. I don't know if the whole code has to be in the enchantment card or the token should contain a validation that reads the enchantment fade counters.

Is there any way of generate a dependency between the cards?

Cheers,
Chris
cristianarodri
 
Posts: 1
Joined: 30 Oct 2013, 13:26
Has thanked: 0 time
Been thanked: 0 time

Re: Talk about new cards here

Postby RiiakShiNal » 30 Oct 2013, 16:05

cristianarodri wrote:Hi All, I'm new in DOTP programming and after some successful test with easy cards, I've tried to move forward and code Saproling Burst.
And you jumped directly to a tough one. I am going to assume you are working on DotP 2014 as you have neglected to mention which version.

cristianarodri wrote:I can code the counters and the token generation, but the P/T of them, I just can't control it. I don't know if the whole code has to be in the enchantment card or the token should contain a validation that reads the enchantment fade counters.

Is there any way of generate a dependency between the cards?
There are a couple of ways though if you are only accustomed to easy cards then it might be too much for you.

The first method is to make use of the DuelDataChest() to set a CardPtr to the pointer of the Saproling Burst card who just initiated the second ability and have the Saproling(s) that just entered the battlefield grab that pointer and store it locally in a LinkedDC() register to refer to the generating card both for setting P/T and for determining when it should be destroyed. In this method the Saproling Burst card itself would not actually do anything for it's last ability as that would be built into the Saprolings. This has the issue that it may be possible to overwrite the CardPtr in the DuelDataChest() before the Saprolings check it allowing them to point to a different instance.

The second method is to make use of the DuelDataChest() to have the Saproling Burst card maintain a list of Saproling tokens it has generated and have the Saproling tokens look for this special chest to see if they were created by a particular Saproling Burst instance to set their P/T (the instance of the Saproling Burst can be stored in a LinkedDC() after the first time it is found to keep overhead to a minimum). This method allows the Saproling Burst to actually have it's final ability activate rather than having the ability built into the Saprolings. This method is easier to make using my ObjectDC Functions as finding and maintaining the chest will be much easier to do. This has greater overhead than the first method (though it can be minimized some), but should be safer from an instance standpoint. Also this should be more correct in how things should actually work.

There is a third method that would basically require my ObjectDC Functions in that in the same action that the Tokens are put on the battlefield the Saproling Burst would also set on the Tokens' ObjectDC a pointer to itself that the Saprolings would then reference for setting the P/T. Then you could choose whether the Saproling Burst maintains an internal list of Tokens for it's last ability or whether it is coded on the Saprolings themselves.

It should be noted though that putting the destroy ability on the saprolings is technically incorrect as it is possible activate the second ability from Saproling Burst, then before it resolves destroy (or exile) Saproling Burst which would trigger the Third ability which would destroy all tokens created by Saproling Burst, then have the second ability resolve putting one (or more) tokens on the battlefield that could then remain on the battlefield. For example there is a Coat of Arms in play and you have a Doubling Season, you use the second ability on Saproling Burst, your opponent uses Disenchant on the Saproling Burst before the ability resolves, Saproling Burst goes to the graveyard, tokens are destroyed, then 2 Saprolings enter the battlefield and remain on the battlefield as 1/1 Saprolings due to Coat of Arms effect which prevents them from becoming 0/0 and Saproling Burst is no longer there to destroy them.
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 496 times

Re: Talk about new cards here

Postby SweetestLamb » 06 Jul 2014, 22:06

Hey guys, I'm having trouble with an ability on one of my creatures, it's supposed to make target player lose 1 life. It targets a player, but then does nothing. Am I doing something wrong?

Code: Select all
<TARGET tag="CARD_QUERY_CHOOSE_PLAYER_LOSE_LIFE" definition="0" compartment="0" count="1" />
<TARGET_DEFINITION id="0">
    local filter = ClearFilter()
    filter:SetFilterType( FILTER_TYPE_PLAYERS )
</TARGET_DEFINITION>
<RESOLUTION_TIME_ACTION>
    local target = EffectDC():Get_Targets(0):Get_PlayerPtr(0)
    if target ~= nil then
   target:LoseLife(1)
</RESOLUTION_TIME_ACTION>
SweetestLamb
 
Posts: 10
Joined: 06 Jul 2014, 14:43
Has thanked: 1 time
Been thanked: 0 time

Re: Talk about new cards here

Postby RiiakShiNal » 06 Jul 2014, 22:12

You forgot to close the if statement:
Code: Select all
<RESOLUTION_TIME_ACTION>
    local target = EffectDC():Get_Targets(0):Get_PlayerPtr(0)
    if target ~= nil then
      target:LoseLife(1)
    end
</RESOLUTION_TIME_ACTION>
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 496 times

Re: Talk about new cards here

Postby NEMESiS » 07 Jul 2014, 23:30

I have a question about cards that I am not too sure where to post. Basically, through modding from 2012, 2013 and 2014 I noticed that on deck lists some cards are marked differently. For example, here is a deck list for Peacekeepers in 2013:

| Open
<CARD name="GLORIOUS_ANTHEM_280044" deckOrderId="0" />
<CARD name="GLORIOUS_ANTHEM_280044@2" deckOrderId="1" />
<CARD name="RAISE_THE_ALARM_277159" deckOrderId="2" />
<CARD name="RAISE_THE_ALARM_277159" deckOrderId="3" />
<CARD name="HONOR_OF_THE_PURE_277112#" deckOrderId="4" />
<CARD name="HONOR_OF_THE_PURE_277112" deckOrderId="5" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="6" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="7" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="8" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="9" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881#" deckOrderId="10" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881@3" deckOrderId="11" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881" deckOrderId="12" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="13" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="14" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="15" />
<CARD name="ACCORDER_PALADIN_277124" deckOrderId="16" />
<CARD name="ACCORDER_PALADIN_277124" deckOrderId="17" />
<CARD name="ACCORDER_PALADIN_277124#" deckOrderId="18" />
<CARD name="FIEND_HUNTER_277036@3" deckOrderId="19" />
<CARD name="FIEND_HUNTER_277036@3" deckOrderId="20" />
<CARD name="DAWN_ELEMENTAL_281244" deckOrderId="21" />
<CARD name="DAWN_ELEMENTAL_281244#" deckOrderId="22" />
<CARD name="ATTENDED_KNIGHT_301071" deckOrderId="23" />
<CARD name="ATTENDED_KNIGHT_301071" deckOrderId="24" />
<CARD name="GEISTHONORED_MONK_280245" deckOrderId="25" />
<CARD name="GEISTHONORED_MONK_280245@3" deckOrderId="26" />
<CARD name="ARCHON_OF_JUSTICE_281221" deckOrderId="27" />
<CARD name="ARCHON_OF_JUSTICE_281221" deckOrderId="28" />
<CARD name="GUARDIANS_PLEDGE_277110" deckOrderId="29" />
<CARD name="GUARDIANS_PLEDGE_277110#" deckOrderId="30" />
<CARD name="OBLIVION_RING_276959@2" deckOrderId="31" />
<CARD name="OBLIVION_RING_276959@2" deckOrderId="32" />
<CARD name="JOURNEY_TO_NOWHERE_276937" deckOrderId="33" />
<CARD name="JOURNEY_TO_NOWHERE_276937" deckOrderId="34" />


I get that for 2013 the hash-tag means that the card is a promo. However, my question is in reference to cards that end with @3 or @2. This seems common on all DotP games, do any of you know what this means?
User avatar
NEMESiS
 
Posts: 460
Joined: 03 Jan 2013, 04:02
Location: Pools of Becoming
Has thanked: 70 times
Been thanked: 21 times

Re: Talk about new cards here

Postby SweetestLamb » 07 Jul 2014, 23:54

I'm currently working on a Naya deck for a friend. I'm looking for Mayael, The Anima and her Aria. I've noticed several posts saying that they've been coded before but I can't find the cards themselves. Can anyone help me?
SweetestLamb
 
Posts: 10
Joined: 06 Jul 2014, 14:43
Has thanked: 1 time
Been thanked: 0 time

Re: Talk about new cards here

Postby RiiakShiNal » 08 Jul 2014, 00:02

NEMESiS wrote:I have a question about cards that I am not too sure where to post. Basically, through modding from 2012, 2013 and 2014 I noticed that on deck lists some cards are marked differently. For example, here is a deck list for Peacekeepers in 2013:

| Open
<CARD name="GLORIOUS_ANTHEM_280044" deckOrderId="0" />
<CARD name="GLORIOUS_ANTHEM_280044@2" deckOrderId="1" />
<CARD name="RAISE_THE_ALARM_277159" deckOrderId="2" />
<CARD name="RAISE_THE_ALARM_277159" deckOrderId="3" />
<CARD name="HONOR_OF_THE_PURE_277112#" deckOrderId="4" />
<CARD name="HONOR_OF_THE_PURE_277112" deckOrderId="5" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="6" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="7" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="8" />
<CARD name="CAPTAINS_CALL_301076" deckOrderId="9" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881#" deckOrderId="10" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881@3" deckOrderId="11" />
<CARD name="CAPTAIN_OF_THE_WATCH_276881" deckOrderId="12" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="13" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="14" />
<CARD name="ELITE_VANGUARD_276907" deckOrderId="15" />
<CARD name="ACCORDER_PALADIN_277124" deckOrderId="16" />
<CARD name="ACCORDER_PALADIN_277124" deckOrderId="17" />
<CARD name="ACCORDER_PALADIN_277124#" deckOrderId="18" />
<CARD name="FIEND_HUNTER_277036@3" deckOrderId="19" />
<CARD name="FIEND_HUNTER_277036@3" deckOrderId="20" />
<CARD name="DAWN_ELEMENTAL_281244" deckOrderId="21" />
<CARD name="DAWN_ELEMENTAL_281244#" deckOrderId="22" />
<CARD name="ATTENDED_KNIGHT_301071" deckOrderId="23" />
<CARD name="ATTENDED_KNIGHT_301071" deckOrderId="24" />
<CARD name="GEISTHONORED_MONK_280245" deckOrderId="25" />
<CARD name="GEISTHONORED_MONK_280245@3" deckOrderId="26" />
<CARD name="ARCHON_OF_JUSTICE_281221" deckOrderId="27" />
<CARD name="ARCHON_OF_JUSTICE_281221" deckOrderId="28" />
<CARD name="GUARDIANS_PLEDGE_277110" deckOrderId="29" />
<CARD name="GUARDIANS_PLEDGE_277110#" deckOrderId="30" />
<CARD name="OBLIVION_RING_276959@2" deckOrderId="31" />
<CARD name="OBLIVION_RING_276959@2" deckOrderId="32" />
<CARD name="JOURNEY_TO_NOWHERE_276937" deckOrderId="33" />
<CARD name="JOURNEY_TO_NOWHERE_276937" deckOrderId="34" />


I get that for 2013 the hash-tag means that the card is a promo. However, my question is in reference to cards that end with @3 or @2. This seems common on all DotP games, do any of you know what this means?
The at symbol, @, and the number after it are used for biased shuffling (for the AI). The number represents the difficulty at which it should stop being biased (which is why you don't see any with "@1"). The biased shuffling works by shuffling biased cards towards the bottom of the deck rather than a true shuffle which could put the card anywhere. For example in the above deck both copies of Oblivion Ring would be shuffled towards the bottom of the deck for the AI in the easiest difficulty, but would be shuffled normally in the two higher difficulties. Also both copies of Fiend Hunter are biased such that on all but the highest difficulty they will be shuffled towards the bottom of the deck. In the case of Geist-Honored Monk only one is biased and will only be shuffled normally at the highest difficulty, but the other will always be shuffled normally.

So if you always play at the highest difficulty level you will never notice the effects, if you play at easier difficulty levels you may notice that the AI doesn't typically get the biased cards during most games (because those cards have been shuffled towards the bottom of their deck).
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 496 times

Re: Talk about new cards here

Postby NEMESiS » 08 Jul 2014, 14:40

Interesting, I actually assumed that the opposite was true. That the number represents a bias in shuffling towards the top of the deck rather then to the bottom depending on difficulty.


SweetestLamb wrote:I'm currently working on a Naya deck for a friend. I'm looking for Mayael, The Anima and her Aria. I've noticed several posts saying that they've been coded before but I can't find the cards themselves. Can anyone help me?
I think GrovyleXShinyCelebi has it on his mod:

viewtopic.php?f=109&t=12934
User avatar
NEMESiS
 
Posts: 460
Joined: 03 Jan 2013, 04:02
Location: Pools of Becoming
Has thanked: 70 times
Been thanked: 21 times

Re: Talk about new cards here

Postby RiiakShiNal » 08 Jul 2014, 15:59

NEMESiS wrote:Interesting, I actually assumed that the opposite was true. That the number represents a bias in shuffling towards the top of the deck rather then to the bottom depending on difficulty.
It's basically designed to try and prevent the AI from getting certain cards (often more powerful cards in that deck) on easier difficulties to make it easier for beginning players. It doesn't affect shuffling on the player's deck at all.
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 496 times

Re: Talk about new cards here

Postby SweetestLamb » 09 Jul 2014, 14:00

NEMESiS wrote:Interesting, I actually assumed that the opposite was true. That the number represents a bias in shuffling towards the top of the deck rather then to the bottom depending on difficulty.


SweetestLamb wrote:I'm currently working on a Naya deck for a friend. I'm looking for Mayael, The Anima and her Aria. I've noticed several posts saying that they've been coded before but I can't find the cards themselves. Can anyone help me?
I think GrovyleXShinyCelebi has it on his mod:

viewtopic.php?f=109&t=12934
I actually ended up solving these on my own. I do have a different question. I'm working on Retaliator Griffin as well, but I can't seem to get it to trigger.

I'm using TRIGGER_SOURCE_DEALS_DAMAGE, but I'm not sure what the TriggerObject() refers to or how to check to see if it was the griffin's owner that got damaged. Any advice?
SweetestLamb
 
Posts: 10
Joined: 06 Jul 2014, 14:43
Has thanked: 1 time
Been thanked: 0 time

Re: Talk about new cards here

Postby RiiakShiNal » 09 Jul 2014, 17:48

SweetestLamb wrote:I'm working on Retaliator Griffin as well, but I can't seem to get it to trigger.

I'm using TRIGGER_SOURCE_DEALS_DAMAGE, but I'm not sure what the TriggerObject() refers to or how to check to see if it was the griffin's owner that got damaged. Any advice?
You probably want to use SOURCE_DEALS_DAMAGE_TO_PLAYER (remember in TRIGGER values you omit the starting TRIGGER_ from the constants) instead for the TRIGGER value. TriggerObject() will be the card that dealt the damage, SecondaryPlayer() will be the player damaged, and Damage() would be the damage object which can tell you how much damage was dealt.
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 496 times

PreviousNext

Return to Programming Talk

Who is online

Users browsing this forum: No registered users and 43 guests


Who is online

In total there are 43 users online :: 0 registered, 0 hidden and 43 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 43 guests

Login Form