It is currently 25 Apr 2024, 08:16
   
Text Size

Implemented card not showing up in deck editor

Moderators: North, BetaSteward, noxx, jeffwadsworth, JayDi, TheElk801, LevelX, CCGHQ Admins

Implemented card not showing up in deck editor

Postby Julia » 27 Jun 2015, 04:37

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.
Attachments
Rootgrapple.txt
(3.74 KiB) Downloaded 233 times
Julia
 
Posts: 20
Joined: 05 Apr 2015, 14:17
Has thanked: 8 times
Been thanked: 2 times

Re: Implemented card not showing up in deck editor

Postby LevelX » 27 Jun 2015, 04:55

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.
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implemented card not showing up in deck editor

Postby LevelX » 27 Jun 2015, 04:59

Your source code is flawless.
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implemented card not showing up in deck editor

Postby Julia » 27 Jun 2015, 05:37

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.
Julia
 
Posts: 20
Joined: 05 Apr 2015, 14:17
Has thanked: 8 times
Been thanked: 2 times

Re: Implemented card not showing up in deck editor

Postby LevelX » 27 Jun 2015, 07:27

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.
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implemented card not showing up in deck editor

Postby Julia » 09 Jul 2015, 15:18

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?
Julia
 
Posts: 20
Joined: 05 Apr 2015, 14:17
Has thanked: 8 times
Been thanked: 2 times

Re: Implemented card not showing up in deck editor

Postby Julia » 09 Jul 2015, 15:39

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.
Julia
 
Posts: 20
Joined: 05 Apr 2015, 14:17
Has thanked: 8 times
Been thanked: 2 times

Re: Implemented card not showing up in deck editor

Postby LevelX » 09 Jul 2015, 17:49

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.
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times


Return to Developers Talk

Who is online

Users browsing this forum: No registered users and 11 guests


Who is online

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

Login Form