It is currently 14 Sep 2025, 23:28
   
Text Size

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: Big commit, no dice / SVN hugely broken on r10194

Postby Max mtg » 15 Sep 2011, 13:11

The quickest fix would be to put the [battle] section after metadata, main and sideboard ones... but I don't like this solution. I'll instruct deckmanager to find the sections it can process and parse them regardless of their order in the file
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

Postby Doublestrike » 15 Sep 2011, 13:15

Uhhh...so I don't have to change anything? :shock: Wasn't expecting that, hope it's true...my hopes have risen. :)
---
A joke is a very serious thing.
User avatar
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

Postby Rob Cashwalker » 15 Sep 2011, 13:16

Custom Draft uses a deck file to make creation and maintenance simple, using the existing deck editor. JuzamJedi's cube deck file appears in the deck lists, and I want to prevent that, by using a meta data tag.

A custom cardpool deck is not likely to play very well as an actual deck.. though some folks have tried..
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby Max mtg » 15 Sep 2011, 13:19

I have tried to play with JuzamJedi's cube - a couple of mulligans, but still no lands!
That is why I ask to separate decks from limited game cubes.

If the obstacle is about enabling deckeditor to work with cubes packed into a single file, let's just do it.
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

Postby Rob Cashwalker » 15 Sep 2011, 14:02

There are two ways to go...
- actually isolate custom pool deck files, while still enabling them to be edited
- use the metadata
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby friarsol » 15 Sep 2011, 14:09

We could use a different extension for cubes, so they don't get loaded into the choose a deck option, but the deck editor can still load them properly.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby Rob Cashwalker » 15 Sep 2011, 14:39

The DeckManager would need to know the difference.
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby Max mtg » 15 Sep 2011, 15:49

Doublestrike wrote:Uhhh...so I don't have to change anything? :shock: Wasn't expecting that, hope it's true...my hopes have risen. :)
Yes, update to 10470 - deckmanager finds the section it should read regardless of their order in file
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

Postby Max mtg » 15 Sep 2011, 15:53

Rob Cashwalker wrote:The DeckManager would need to know the difference.
Why deckmanager?
The limited game cubes should not appear in deckmanager.
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

Postby Rob Cashwalker » 15 Sep 2011, 16:57

DeckManager maintains the list of decks doesn't it? For the DeckEditor to be able to open or save a deck, it needs DeckManager right? The whole point of the custom card pool being a simple deck file is so that it can be edited without special tools. About the only thing I would add to the DeckEditor is a menu option to set the CustomPool flag in the Deck object, but it's something that the cube designer can add to the file by hand.
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby Max mtg » 15 Sep 2011, 19:42

Rob Cashwalker wrote:DeckManager maintains the list of decks doesn't it? For the DeckEditor to be able to open or save a deck, it needs DeckManager right? The whole point of the custom card pool being a simple deck file is so that it can be edited without special tools. About the only thing I would add to the DeckEditor is a menu option to set the CustomPool flag in the Deck object, but it's something that the cube designer can add to the file by hand.
No, deckmanager is wasting time reading all the files in a directory, keeps decks in memory instead of reading them by request. It was also deleting the whole directory and writing decks to disk each time deckeditor is closed some time ago.

Deckedtor already is a special tool - so how is one supposed to edit a cube without special tools?

New options in deckeditor - yes, that is a way to go.
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

Postby Rob Cashwalker » 15 Sep 2011, 20:30

So what is currently in charge of decks?

By special tool, I refer to the "special tool" Rares put together to edit the original draft rarity files....

I wanted the user to be able to use a familiar tool, with all the fancy gui stuff.. oh wait, the DeckEditor already did that... so I decided to simply have the custom draft file reference a particular deck in which to pull cards. The unfortunate side effect was that it showed up as a constructed deck...
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Big commit, no dice / SVN hugely broken on r10194

Postby Doublestrike » 16 Sep 2011, 00:15

Max mtg wrote:Yes, update to 10470 - deckmanager finds the section it should read regardless of their order in file
Great, hugely helpful. At Day Job right now but I should have some time this evening.

One other error which someone might know something about:

In QuestUtil, I have a method to generate bonus cards from a string (i.e. 4 red rares becomes a card list of...that.) BoosterUtils has disappeared. What engine should I use to generate this cardlist?
---
A joke is a very serious thing.
User avatar
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

Postby Max mtg » 16 Sep 2011, 01:38

Doublestrike wrote:
Max mtg wrote:Yes, update to 10470 - deckmanager finds the section it should read regardless of their order in file
Great, hugely helpful. At Day Job right now but I should have some time this evening.

One other error which someone might know something about:

In QuestUtil, I have a method to generate bonus cards from a string (i.e. 4 red rares becomes a card list of...that.) BoosterUtils has disappeared. What engine should I use to generate this cardlist?
Use
Code: Select all
forge.card.BoosterUtils.generateCards(int, CardRarity, String)
or
Code: Select all
forge.card.BoosterUtils.generateCards(Predicate<CardPrinted>, int, CardRarity, String) // if there are other restrictions besides rarity and color.
to generate rewards.
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

Postby Doublestrike » 16 Sep 2011, 02:33

Max mtg wrote:Use
Code: Select all
forge.card.BoosterUtils.generateCards(int, CardRarity, String)
or
Code: Select all
forge.card.BoosterUtils.generateCards(Predicate<CardPrinted>, int, CardRarity, String) // if there are other restrictions besides rarity and color.
to generate rewards.
That's good news, since I'm doing that already. There must be something funny happening with my synchronization because BoosterUtils is acting strangely. Thanks for the reply, I'll have a closer look.
---
A joke is a very serious thing.
User avatar
Doublestrike
UI Programmer
 
Posts: 715
Joined: 08 Aug 2011, 09:07
Location: Bali
Has thanked: 183 times
Been thanked: 161 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 59 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 59 users online :: 0 registered, 0 hidden and 59 guests (based on users active over the past 10 minutes)
Most users ever online was 7967 on 09 Sep 2025, 23:08

Users browsing this forum: No registered users and 59 guests

Login Form