Board index Programs with AI or Rules Enforcement Magic: The Gathering - Duels of the Planeswalkers New MTG Cards and Decks (2010, 2012, 2013, 2014, 2015, Magic Duels) 2014
Deck Edtior Unhandled Exception Help
Moderator: CCGHQ Admins
Deck Edtior Unhandled Exception Help
by Orangewaggs » 09 Feb 2014, 19:26
Hey I was Exporting a deck when this came up
************** Exception Text **************
System.FormatException: One of the identified items was in an invalid format.
at Gibbed.Duels.FileFormats.TdxFile.Serialize(Stream output)
at RSN.DotP.WadBase.AddAiPersonalityImage(String strFilename, TdxWrapper twImage)
at RSN.DotP.DeckBuilder.ExportWad(WadBase wad, String strGameDirectory)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
I Clicked Continue and it still didn't export my deck... I even tryed reinstalling the editor and that didn't work any help would be great...
************** Exception Text **************
System.FormatException: One of the identified items was in an invalid format.
at Gibbed.Duels.FileFormats.TdxFile.Serialize(Stream output)
at RSN.DotP.WadBase.AddAiPersonalityImage(String strFilename, TdxWrapper twImage)
at RSN.DotP.DeckBuilder.ExportWad(WadBase wad, String strGameDirectory)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
I Clicked Continue and it still didn't export my deck... I even tryed reinstalling the editor and that didn't work any help would be great...
-
Orangewaggs - Posts: 17
- Joined: 18 Dec 2013, 23:39
- Has thanked: 8 times
- Been thanked: 0 time
Re: Deck Edtior Unhandled Exception Help
by RiiakShiNal » 09 Feb 2014, 20:34
This error is stating that it had a problem trying to export the AI Personality image. Given that it threw a FormatException and it happened in Gibbed.Duels.FileFormats.TdxFile.Serialize() and not in some deeper .Net code then one of the following must be true:
Personally, I think the most likely answer is #2, the source image is too large, but if that is not the case feel free to attach a "Save" of the deck which shows this problem so I can trace the error and fix it.
- Wrong header flags were set for the image (unlikely as I don't set flags Unknown0, Unknown1, or Unknown12, though it is possible that you are trying to use a game TDX image that has one of those flags set).
- The image is too large (height and/or width is greater than 2048).
- You are trying to use the Deck Builder with a non-modified version of Gibbed Tools (unlikely if you used the files from the Deck Builder zip file as I packaged the Builder with my modified version, additionally I made no changes to that function so if you are using the wrong version the error shouldn't occur there anyway).
Personally, I think the most likely answer is #2, the source image is too large, but if that is not the case feel free to attach a "Save" of the deck which shows this problem so I can trace the error and fix it.
Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2185
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
Re: Deck Edtior Unhandled Exception Help
by Orangewaggs » 09 Feb 2014, 20:37
Okay I think i know what I did. I used an image that was too big Thank you Riiak.
-
Orangewaggs - Posts: 17
- Joined: 18 Dec 2013, 23:39
- Has thanked: 8 times
- Been thanked: 0 time
Re: Deck Edtior Unhandled Exception Help
by RiiakShiNal » 09 Feb 2014, 21:02
Well as long as we figured out what the problem was.
Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2185
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
Re: Deck Edtior Unhandled Exception Help
by Orangewaggs » 12 Feb 2014, 08:16
I figured i would ask here instead of making a new topic but whenever I make a deck that is either Bant or certain 4 color combos or a 5 color deck the land count skyrockets to over 250 and ideas to stop that?
-
Orangewaggs - Posts: 17
- Joined: 18 Dec 2013, 23:39
- Has thanked: 8 times
- Been thanked: 0 time
Re: Deck Edtior Unhandled Exception Help
by RiiakShiNal » 12 Feb 2014, 14:00
This has been covered several times, the problem is not with the Deck Builder (as the Deck Builder does not actually auto-add basic land to a deck). The problem is that the game engine does not like 4+ colour decks and can't handle them properly. The easiest way to get around the problem is to (in the Deck Builder) set the land config (in Deck Information) as follows:Orangewaggs wrote:I figured i would ask here instead of making a new topic but whenever I make a deck that is either Bant or certain 4 color combos or a 5 color deck the land count skyrockets to over 250 and ideas to stop that?
- Ignore Cards with CMC over: 0 (Important as you need to disable automatic land determination.)
- Minimum Forests: <# of basic forests you want in the deck>
- Minimum Islands: <# of basic islands you want in the deck>
- Minimum Mountains: <# of basic mountains you want in the deck>
- Minimum Plains: <# of basic plains you want in the deck>
- Minimum Swamps: <# of basic swamps you want in the deck>
- Number of Spells that count as land: 0 (This should be left at 0 due to a bug in the engine.)
This still will not allow changing land in the in-game deck manager (because the engine can't properly handle 4+ colour decks), but it will allow you to determine exactly what basic lands you want to have in the base 60 card deck.
This will not allow auto-adding lands to make a base deck more than 60 cards as the engine will only auto-add lands to get the base deck up to 60 cards. If you want the base deck to be more than 60 cards then you will have to add land manually to the main deck (the engine only supports up to 100 cards for standard decks including the unlocks).
Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2185
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
6 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 47 guests