Big commit, no dice / SVN hugely broken on r10194
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Re: Commits with errors?
by Doublestrike » 03 Sep 2011, 11:52
That's what I was talking about with an "alternate solution". I'm open to suggestions - at this point, I just do what I'm told.Max mtg wrote:If it were not a requirement, how would you store the data?

BTW @Max - edited my post again, rather than making 3 separate posts. Maybe I should stop doing that too

Also @Max - didn't actually delete those, they're present in my build. Sort of in a haze right now.
---
A joke is a very serious thing.
A joke is a very serious thing.
-
Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Max mtg » 03 Sep 2011, 11:58
Chris, the idea of playtesting these decks without random-encontering them in quest mode is very sane.Chris H. wrote:This quest mode specific metadata should only be used by the AI. And these quest mode AI decks all follow the naming convention of:`
- Code: Select all
"quest" + number
Granted, the Deck Type is no longer a "constructed" type of deck. It might be nice to play test these decks in constructed mode while these special fantasy quest opponent decks are being created/tested/modified.
I think that it is a good idea to move the quest mode specific metadata from being hard coded into the dck file itself.
We may want to consider changing the Deck Type? I'm not sure of the various ramifications but I guess that we should think about it.
Though, constructed mode cannot start with decks like this, at least now. We also should restrict a player from picking that deck... this is why I'm suggesting a separate file format, it can only be different in file extension and the name we give it, but this won't let mix it up with regular decks.
Single class for single responsibility.
- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: Commits with errors?
by Max mtg » 03 Sep 2011, 12:05
As for me, it would be enough at least if we give these files a different extension than regular decks, everything else is up to you.Doublestrike wrote:That's what I was talking about with an "alternate solution". I'm open to suggestions - at this point, I just do what I'm told.Too busy fixing to figure out a solution right now. But just say the word...
BTW @Max - edited my post again, rather than making 3 separate posts. Maybe I should stop doing that too
Also @Max - didn't actually delete those, they're present in my build. Sort of in a haze right now.
The thing I am dreaming about is XML format for quest decks - but I don't insist on that.
I'm not the one to restrict you about that, Doublestrike.
I believe you, but somehow they are gone from SVN... would you restore them, please?
Single class for single responsibility.
- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Doublestrike » 03 Sep 2011, 12:08
If it helps, the decks are constructed with the same format as I saw in other decks, that is:Max mtg wrote:the idea of playtesting these decks without random-encontering them in quest mode is very sane
[metadata]
[main]
[sideboard]
Maybe the solution is add
- Code: Select all
Deck Type=some-new-value
---
A joke is a very serious thing.
A joke is a very serious thing.
-
Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Sloth » 03 Sep 2011, 12:11
These decks are in the quest deck folder, which is not the folder where constructed decks are stored.Max mtg wrote:Chris, the idea of playtesting these decks without random-encontering them in quest mode is very sane.
Though, constructed mode cannot start with decks like this, at least now. We also should restrict a player from picking that deck... this is why I'm suggesting a separate file format, it can only be different in file extension and the name we give it, but this won't let mix it up with regular decks.
I think the best solution is to give them a different Deck type than constructed (maybe "quest"), but leave the dck file type.
-
Sloth - Programmer
- Posts: 3498
- Joined: 23 Jun 2009, 19:40
- Has thanked: 125 times
- Been thanked: 507 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Chris H. » 03 Sep 2011, 12:15
`Max mtg wrote:Chris, the idea of playtesting these decks without random-encontering them in quest mode is very sane.
Though, constructed mode cannot start with decks like this, at least now. We also should restrict a player from picking that deck... this is why I'm suggesting a separate file format, it can only be different in file extension and the name we give it, but this won't let mix it up with regular decks.
Agreed, we do not want to confuse the user base.
It might be possible to change the Deck Type metadata instead. Or have a separate file format. Either way, we would need some code added to make this work.
-
Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Doublestrike » 03 Sep 2011, 12:25
OK I'm pretty fried at this point and can't get my head around a conversion from a Card object to a CardPrinted.
The biggest errors are coming from QuestUtil.java > getHumanExtraCards() and QuestUtil.java > getAIExtraCards() which adds the extra cards during the quest game. My previous configuration had these built as Card objects, but now they have to be built as CardPrinted (I think).
I seriously can't work on this right now, it's late at night and I'm done. I can attack it tomorrow. If someone wants to jump on it, that's the problem. It seems like other things are working well.
Other errors are coming in the Forge/ root folder, but I'm not sure they're related to my huge mistake.
So, I'll be back later (give me 12-16 hours). And I'll be sure to update my damn SVN before I make a move.
The biggest errors are coming from QuestUtil.java > getHumanExtraCards() and QuestUtil.java > getAIExtraCards() which adds the extra cards during the quest game. My previous configuration had these built as Card objects, but now they have to be built as CardPrinted (I think).
I seriously can't work on this right now, it's late at night and I'm done. I can attack it tomorrow. If someone wants to jump on it, that's the problem. It seems like other things are working well.
Other errors are coming in the Forge/ root folder, but I'm not sure they're related to my huge mistake.
So, I'll be back later (give me 12-16 hours). And I'll be sure to update my damn SVN before I make a move.
---
A joke is a very serious thing.
A joke is a very serious thing.
-
Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Doublestrike » 03 Sep 2011, 12:28
BTW, I can change metas very easily. I have a script for working with the dck files that can finish this chore in seconds.Chris H. wrote:Either way, we would need some code added to make this work.
Battle decks have been meta-d with Deck Type=constructed. Quest decks have not been meta-d. Once a decision is reached, I can jump into action.
---
A joke is a very serious thing.
A joke is a very serious thing.
-
Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Chris H. » 03 Sep 2011, 12:44
`Doublestrike wrote:Battle decks have been meta-d with Deck Type=constructed. Quest decks have not been meta-d. Once a decision is reached, I can jump into action.
Yeah, we want the battle decks to continue to use "Deck Type=constructed". Imagine, during a (randomly chosen deck) constructed mode game that we would have an option for the computer to use one of the AI decks contained in the /res/quest/decks/ folder.

-
Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Doublestrike » 03 Sep 2011, 12:44
Trying out this multiple-post-not-editing thing... 
@Max - Also, I made a post a little while ago about the errors you mentioned.
First, if I may provide a rebuttal:


@Max - Also, I made a post a little while ago about the errors you mentioned.
First, if I may provide a rebuttal:
Ahh, there, we differ. Apparently, quest decks are more than main and sideboard, because there's bonus cards at the beginning of the match.Max mtg wrote:Deck is a set of cards, some of them are main deck and all others are sideboard.
True.Max mtg wrote:A deck can be picked for a match against other player, be it computer or human (I mean AI can pick that deck and play against you).
Also true. But in quest, and possibly other modes, the starting game state can be unusual.Max mtg wrote:Deck can be opened and edited in a deck editor, exported to some other site or program... and it's functionality won't change because of that. It's still a set of cards for one player to start game with.
This sounds great!Max mtg wrote:The thing I am dreaming about is XML format for quest decks - but I don't insist on that.
I think I did in r10201...not sure about anything anymore.Max mtg wrote:I believe you, but somehow they are gone from SVN... would you restore them, please?

It seems that the "new" deck format (with [metadata]) allows any type of deck, with any details. The code can choose the parts it needs - if no "extras" then just don't grab them from the Deck object.Chris H wrote:Imagine, during a (randomly chosen deck) constructed mode game that we would have an option for the computer to use one of the AI decks contained in the /res/quest/decks/ folder.
---
A joke is a very serious thing.
A joke is a very serious thing.
-
Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Chris H. » 03 Sep 2011, 13:15
`Doublestrike wrote:I think I did in r10201...not sure about anything anymore.Max mtg wrote:I believe you, but somehow they are gone from SVN... would you restore them, please?
Ah, thank you. This rev added in the two missing classes that were somehow deleted from the SVN.
The error count on my local copy went from 353 down to 6. The 6 current errors are:
- Code: Select all
Description Resource Path Location Type
The method getHumanExtraCards(QuestData, DeckSingleQuest) is undefined for the type QuestUtil QuestMainPanel.java /ForgeSVN/src/main/java/forge/quest/gui line 720 Java Problem
The method getHumanExtraCards(QuestData) is undefined for the type QuestUtil QuestMainPanel.java /ForgeSVN/src/main/java/forge/quest/gui line 697 Java Problem
The method getQuestAssignment() is undefined for the type AllZone GameAction.java /ForgeSVN/src/main/java/forge line 618 Java Problem
The method getQuestAssignment() is undefined for the type AllZone GameAction.java /ForgeSVN/src/main/java/forge line 1013 Java Problem
The method setQuestAssignment(null) is undefined for the type AllZone Gui_WinLose.java /ForgeSVN/src/main/java/forge line 353 Java Problem
The method setQuestAssignment(Quest_Assignment) is undefined for the type AllZone QuestMainPanel.java /ForgeSVN/src/main/java/forge/quest/gui/main line 703 Java Problem
-
Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Max mtg » 03 Sep 2011, 13:22
You've just ruined the concept of deck with your commit by adding extrahuman and ai cardsDoublestrike wrote:I think I did in r10201...not sure about anything anymore.
Single class for single responsibility.
- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Sloth » 03 Sep 2011, 13:36
If you are so passionate about keeping the decks clean and simple, you can help us come up with a good slolution of what to do with the quest data. Maybe a class called QuestDeck of which Deck is a parent?Max mtg wrote:You've just ruined the concept of deck with your commit by adding extrahuman and ai cardsDoublestrike wrote:I think I did in r10201...not sure about anything anymore.
-
Sloth - Programmer
- Posts: 3498
- Joined: 23 Jun 2009, 19:40
- Has thanked: 125 times
- Been thanked: 507 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Max mtg » 03 Sep 2011, 13:44
Of course, different class is needed. And it should not inherit, but include the deck, and avoid storing metadata in hashtable, since the entries of it have different meaning.Sloth wrote:If you are so passionate about keeping the decks clean and simple, you can help us come up with a good slolution of what to do with the quest data. Maybe a class called QuestDeck of which Deck is a parent?Max mtg wrote:You've just ruined the concept of deck with your commit by adding extrahuman and ai cardsDoublestrike wrote:I think I did in r10201...not sure about anything anymore.
Moreover, I can take care of that, but as soon as the SVN is restored to a buildable state. (otherwise I'll have to rollback doublestrike's changes)
Single class for single responsibility.
- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: Big commit, no dice / SVN hugely broken on r10194
by Sloth » 03 Sep 2011, 13:53
Thank you Max. You seem to have a clear layout of what this part of the code should look like in mind. I'm sure Doublestrike is fine with what solution you will come up.Max mtg wrote:Of course, different class is needed. And it should not inherit, but include the deck, and avoid storing metadata in hashtable, since the entries of it have different meaning.
Moreover, I can take care of that, but as soon as the SVN is restored to a buildable state. (otherwise I'll have to rollback doublestrike's changes)
-
Sloth - Programmer
- Posts: 3498
- Joined: 23 Jun 2009, 19:40
- Has thanked: 125 times
- Been thanked: 507 times
Who is online
Users browsing this forum: No registered users and 27 guests