It is currently 27 Apr 2024, 17:30
   
Text Size

Morph tests

Moderator: CCGHQ Admins

Morph tests

Postby gorem2k » 30 Aug 2014, 18:19

The subject says it all. It's about the possibility of implementing Morph.

I found a silly way of making a fake face down creature pass thru stack but it does strange (and not really recommended) things before it can happen.



I post the cards here in case someone want to help me make an approximation.

(see 3rd post below.)
Last edited by gorem2k on 01 Sep 2014, 12:15, edited 2 times in total.
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby gorem2k » 30 Aug 2014, 18:30

i was thinking, maybe it's possible at turn 0 of game before it begins, at least asap, to convert all cards that has morph ability in all players library/hand to the token then exile the token so all these cards are facedown when they enter stack. but yeah we won't see the card faceup so each of them will look the same.. oh well
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby gorem2k » 31 Aug 2014, 14:46

text permanent:
Code: Select all
   <Row>
    <Cell ss:StyleID="s62"><Data ss:Type="String">CARD_QUERY_MODE_CREATURE_GET_2_LOSE_2</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String"></Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:Index="9" ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets +2/-2 until end of turn.</Data></Cell>
   </Row>
   <Row>
    <Cell ss:StyleID="s62"><Data ss:Type="String">CARD_QUERY_MODE_CREATURE_LOSE_2_GET_2</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String"></Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:Index="9" ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Target creature gets -2/+2 until end of turn.</Data></Cell>
   </Row>
   <Row>
    <Cell ss:StyleID="s62"><Data ss:Type="String">CARD_QUERY_CHOOSE_CREATURE_TO_GET_2_LOSE_2</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String"></Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Choose a creature to get +2/-2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Choisissez une créature pour lui faire gagner +2/-2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Elige una criatura para que obtenga +2/-2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Bestimme eine Kreatur, die +2/-2 erhalten soll.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Scegli una creatura che prende +2/-2.</Data></Cell>
    <Cell ss:Index="9" ss:StyleID="s62"><Data ss:Type="String">+2/-2の修整を受けるクリーチャーを選択。</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">+2/-2을 받을 생물 한 개를 고르십시오.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Выберите существо, которое получит +2/-2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Escolha uma criatura para receber +2/-2.</Data></Cell>
   </Row>
   <Row>
    <Cell ss:StyleID="s62"><Data ss:Type="String">CARD_QUERY_CHOOSE_CREATURE_TO_LOSE_2_GET_2</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String"></Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Choose a creature to get -2/+2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Choisissez une créature pour lui faire gagner -2/+2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Elige una criatura para que obtenga -2/+2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Bestimme eine Kreatur, die -2/+2 erhalten soll.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Scegli una creatura che prende -2/+2.</Data></Cell>
    <Cell ss:Index="9" ss:StyleID="s62"><Data ss:Type="String">-2/+2の修整を受けるクリーチャーを選択。</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">-2/+2을 받을 생물 한 개를 고르십시오.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Выберите существо, которое получит -2/+2.</Data></Cell>
    <Cell ss:StyleID="s62"><Data ss:Type="String">Escolha uma criatura para receber -2/+2.</Data></Cell>
   </Row>
v10 : removed the option question, AI was no longer playing the card with paymanacost, so i changed back to utility cost. now it's playing better. some notable flaws; image is stretched when turned face up. should be easy to fix by changing token frame/image. still can't look at "fake facedown" card. faceup ability resolves before the card is turned up, no way for a human player to know what the card does and respond accordingly. hmmm maybe more it's an heavy approximation. but still, is a feature missing in DotP. I don't think I'll do Vesuvan Shapeshifter :lol:
Attachments
morph_test10.zip
OUTDATED!
(315.22 KiB) Downloaded 292 times
Last edited by gorem2k on 10 Sep 2014, 16:39, edited 1 time in total.
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby gorem2k » 01 Sep 2014, 01:51

Hey guys, i'm done for tests now. I'm looking for your feedback on this approximation. it's getting somewhere I think.. I can't see any good way to do morph but at least, it's a start. I flickered a facedown creature and it returned faceup, but i don't know if it should trigger when this happen.. it's an odd mechanic to work with.
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby NeoAnderson » 01 Sep 2014, 02:43

As i remember i made some test on morph long time ago, but i was crashing on the DOTP Engine who handles the TurnFaceDown(), TurnFaceUp() functions in a weird way. The card always turns face up into the stack, and other and other bugs...probably your approach is similar with the Firemind's approach to Transform.
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Morph tests

Postby Kithkin » 01 Sep 2014, 09:10

Here is an article you might be interested in. Among other things, it deals with MORPH.
http://magic.wizards.com/en/articles/ar ... ans-tarkir
User avatar
Kithkin
 
Posts: 456
Joined: 21 Feb 2014, 07:12
Location: Cologne, GERMANY
Has thanked: 11 times
Been thanked: 56 times

Re: Morph tests

Postby gorem2k » 01 Sep 2014, 12:13

Nice! I just don't really know if it's worth optimizing. At least it keeps me busy before I start my new daytime job.

Yes I read that article. I know some upcoming cards will use morph. Not that they look awesome for their cost but still, we might be surprised!

As for tfm transform, it's well-structured and I didn't completely analyze how it work so I don't know if it's similar in a way. there's a solid reason why he gave up on morph but I don't know exactly all the details (it's been a while). There may have some messages I didn't saw in forum which explain further, I just didn't catch all of them. It's growing fast.
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby NeoAnderson » 08 Sep 2014, 19:33

gorem2k wrote:Nice! I just don't really know if it's worth optimizing. At least it keeps me busy before I start my new daytime job.

Yes I read that article. I know some upcoming cards will use morph. Not that they look awesome for their cost but still, we might be surprised!

As for tfm transform, it's well-structured and I didn't completely analyze how it work so I don't know if it's similar in a way. there's a solid reason why he gave up on morph but I don't know exactly all the details (it's been a while). There may have some messages I didn't saw in forum which explain further, I just didn't catch all of them. It's growing fast.
I am working on this project too, i have made my own version but i still have to resolve some issues, i will post here later an alpha version just to share for tests, it still need to be adjusted, so it can be more compliant to all the MTG rules.
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Morph tests

Postby gorem2k » 08 Sep 2014, 20:07

Good luck! I gave up because

A: I couldn't figure out a granted ability. (0: view card face-up)
and
B: Not much people seemed interested into this.

I look forward to your take on it tho. Cheers
gorem2k
 
Posts: 464
Joined: 01 Apr 2013, 04:21
Has thanked: 48 times
Been thanked: 33 times

Re: Morph tests

Postby NeoAnderson » 08 Sep 2014, 20:21

gorem2k wrote:Good luck! I gave up because

A: I couldn't figure out a granted ability. (0: view card face-up)
and
B: Not much people seemed interested into this.

I look forward to your take on it tho. Cheers
I am sorry if it seemed if i was not interested, but i was focus onto other abilities overload and strive.
We could cooperate to make an acceptable approximation.
My version now is still to modify but i have already a workaround, to view the infos about facedown card.
I am not at pc right now i will post here later.
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Morph tests

Postby NeoAnderson » 09 Sep 2014, 01:41

Ok my friend i am comeback with an alpha version that still need to be improved.
As your version i also used an activated ability and also a token to make my 2/2 creature.
Some differences from your version are :
1. You are not casting the spell, just moving into stack so this not fire the Spell Played trigger.
2. You turn the card into 2/2 creature already onto stack, i made it in hand then i cast it complian to MTG rules.
3. My version has the Creature Type already embended into token.
4. I have included some checks when the spell is destroyed, exiled, returnet to hand, countered, because during all these situations it must be turned face up.
5. The Morph ability (HAND ABILITY) is dinamically granted when you can pay for it.
6. Added a box with card info to show to the player which card is turned face down (Useful also because uses the same language of the game settings, so each player will retrieve the info using his language).
7. I used the official token for facedown cards.

The card i have used for test is : Aphetto Alchemist
You can check my card downloading it here i embed :
1. WAD just to test the card (including all needed files)
2. Source files XML, TDX, TXT.

PICTURE 1. MORPH ABILITY
Image
PICTURE 2. INFOBOX ABILITY TO VIEW HIDDEN CARD INFO
Image
PICTURE 3. INFOBOX
Image
Attachments
MORPH TEST.rar
Morph Alpha test NEO_GOR ver 0.1
(434.78 KiB) Downloaded 313 times
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Morph tests

Postby Kithkin » 09 Sep 2014, 06:26

I will do some tests later today.

In KHANS OF TARKIR there is an interesting new card. Maybe you want to test your skills on it? :idea:
Image
User avatar
Kithkin
 
Posts: 456
Joined: 21 Feb 2014, 07:12
Location: Cologne, GERMANY
Has thanked: 11 times
Been thanked: 56 times

Re: Morph tests

Postby thefiremind » 09 Sep 2014, 08:42

A problem I can see from the screenshots is that anyone can see the morph cost, and that is a hint about what the card could be. I would suggest to write only "Metamorphosis" on the ability text, and put the cost inside the hidden info.

Also, according to this picture:
Original morph overlay card | Open
Image
the art on the overlay card is by Raymond Swanland, you can write that instead of PLACEHOLDER.
< 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: Morph tests

Postby NeoAnderson » 09 Sep 2014, 10:33

Kithkin wrote:I will do some tests later today.

In KHANS OF TARKIR there is an interesting new card. Maybe you want to test your skills on it? :idea:
| Open
Image
This card is not so much complex, the problem right now is to have a good mechanic about morph, this phoenix has just a 2 triggered abilities that execute some effects. If we found the solutions for the mentioned issues it will be easy to implement. So now i am focused to find a good implementation of the Morph ability then we will code everything we want. 8)

thefiremind wrote:A problem I can see from the screenshots is that anyone can see the morph cost, and that is a hint about what the card could be. I would suggest to write only "Metamorphosis" on the ability text, and put the cost inside the hidden info.

Also, according to this picture:
Original morph overlay card | Open
Image
the art on the overlay card is by Raymond Swanland, you can write that instead of PLACEHOLDER.
Both suggestions are smart! As always, and surely i will modify the card according with them, but it's early to have a 100% compliant Morph, there are still some issues using this implementation, i still have to make hard tests to understand if could be improved, or if we have to change a little bit how it is realized.
I report some issues I already found so someone like you and gorem and Riiak can give suggestion to resolve.
Know issues until now :


    1. I haven't found any function who really check if you can cast or not a spell, "CanCastSpellForFree" - "CanCastSpellUsingResourceCost" - "CanBePlayed", no-one really return the right condition. Example we have in play Ethersworn Canonist and we already cast a spell this turn, we are still able to cast the facedown card.

    2. The cost reduction of morph( Hand Ability ), is reduced considering the status of the face-up card (in this case Blue-Spell creature), this is not right according to the rules the face-down spell cost should be reduced only for generic spell, facedown spell, and creature spell.

    3. If a card give the ability to play a card from other zone (Normal play frome exile, graveyard, top of library, paying it's costs) we are not able to cast face-sown spell. This is the same issue i found with OverLoad cards, and could be a minor issue because there are really few cards who grant this ability, most of them grant the ability to cast without paying mana cost and in this case the face-up cast is the only possibility according with the MTG rules. Card to tests the mentioned issue are for example : Nightveil Specter

    4. As i wrote the code i am not sure what happen when a card make a copy of the card when it is face-down onto stack, i have to make some tests, because i have the token to auto-eliminate itself before it comes onto battlefield if the source zone is not the hand, so if 2 + 2 = 4, i think if we make a copy of the face-down card it will be canceled while is onto stack(Still to verify).

UPDATE: I made some changes according with Firemind suggestions:
1. I combined the View info ability with morph to original card ability. I removed the cost from morph to original ability, now it is payed while you show the info, using EffectController():CanPayManaCost("{U}"). I think could be more clean doing in this way.
2. I also add the artist name to the morph facedown token.
3. I also removed the FireTrigger "Turned_Face_Up" when the card is countered, destroyed, exiled...according to MTG rules :
Morph triggers occur when you use the Morph ability to turn the card face up, or when an effect turns it face up. It will not trigger on being revealed or on leaving play
Update token :
Image
Update morph ability / info box :
Image
Attachments
MORPH TEST.rar
Morph Alpha test NEO_GOR ver 0.2
(434.97 KiB) Downloaded 298 times
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Morph tests

Postby NeoAnderson » 09 Sep 2014, 17:23

I am just working on a different version, i almost finished i still have to make some additional tests but until now i can say:
It is compliant and working with the follow cards (who doesn't work with the other version) :


I will come soon with updated notices!
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Next

Return to Programming Talk

Who is online

Users browsing this forum: No registered users and 34 guests

cron

Who is online

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

Login Form