Page 1 of 1

Implemented card not showing up in deck editor

PostPosted: 27 Jun 2015, 04:37
by Julia
So I have no experience developing for xmage, but I wanted to see if I were able to contribute with something. I tried writing the card Rootgrapple by generating the template with gen-card.pl, then adding its abilities (attached the .java file as .txt to this post). The .java file is located within Lorwyn's set directory together with the other cards. I check "Force Database Update" before connecting to my local server, but the card does not appear when I search for it in the deck editor. What do I need to do differently?

Also what type of login does one use for the implementation tracker at ct-magefree.rhcloud? Without a login I'm unable to see the Status/Actions for cards, and I can't find any way to register.

Re: Implemented card not showing up in deck editor

PostPosted: 27 Jun 2015, 04:55
by LevelX
Did you build the Mage Sets project before testing?

An already registered user has to add you to the card tracker.
I will do it later. But the states of the cards should be already visible.

Re: Implemented card not showing up in deck editor

PostPosted: 27 Jun 2015, 04:59
by LevelX
Your source code is flawless.

Re: Implemented card not showing up in deck editor

PostPosted: 27 Jun 2015, 05:37
by Julia
LevelX wrote:Did you build the Mage Sets project before testing?

An already registered user has to add you to the card tracker.
I will do it later. But the states of the cards should be already visible.
I had built it initially before I started writing the card, but did not build it once more after implementation. I built it again now, and it showed up in the deck editor. Thanks!

By the way, when I was adding conditional drawing effect, I was using Aquitect's Will as reference, but I noticed something strange in the code:

Code: Select all
// If you control a Merfolk, draw a card.
        this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
                new DrawCardSourceControllerEffect(1),
                new PermanentsOnTheBattlefieldCondition(new FilterControlledCreaturePermanent("Merfolk", "Merfolk")),
                "If you control a Merfolk, draw a card"));
By using "FilterControlledCreaturePermanent", would that not limit the condition to Merfolk creatures, as opposed to Merfolk permanents in general? If that's the case, it could create problems with non-creature Merfolk permanents such as Merrow Commerce.

Re: Implemented card not showing up in deck editor

PostPosted: 27 Jun 2015, 07:27
by LevelX
Julia wrote:By using "FilterControlledCreaturePermanent", would that not limit the condition to Merfolk creatures, as opposed to Merfolk permanents in general? If that's the case, it could create problems with non-creature Merfolk permanents such as Merrow Commerce.
Good finding. You're absolutely right. It has to be FilterControlledPermanent instead of FilterControlledCreaturePermanent.

Thanks, I'll fix it.

Re: Implemented card not showing up in deck editor

PostPosted: 09 Jul 2015, 15:18
by Julia
I just implemented 8 cards from DIS, yet only 4 of them show up in deck editor. I've build both Root and Sets with dependencies, but only half of them are showing up.

Any idea what I could be doing wrong?

Re: Implemented card not showing up in deck editor

PostPosted: 09 Jul 2015, 15:39
by Julia
Update: I tried to implement another card to see if it showed up, and it did. But several of the others still don't. In one case, the generated card shows up, but not the changes I made to it.

Re: Implemented card not showing up in deck editor

PostPosted: 09 Jul 2015, 17:49
by LevelX
Two things:
1) If you change the text base for card rule generation you have to delete the server DB files before its next startup to get the changes in the server DB and from there to the client DB that is used from thr deck editor.
The server creates all DB records of cards missing in the DB on start up. But it does not update a record if the record already exists (that's the reason to delete the DB).

2) When you connect the client to the server activate the "force DB update" checkbox. So the client DB is updated from the server DB also if there is no change in DB version number.

If you take care about this, you should always be able to see your changes reflected in the card DB files.