Bug Reports (snapshot builds)
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Re: Bug Reports (snapshot builds)
by myk » 20 Mar 2013, 16:26
A note on this -- if we cache an image (null, or a default) when the file is not found, then newly downloaded images may not show up until Forge is reloaded. On the other hand, if a file is not found once, it is likely to not be found again. How about if we clear the cache after any GuiDownloader run so new images show up properly, yet we prevent hammering the file system looking for missing files?Chris H. wrote:Looks like we are attempting to assign an Image via it's key to a BufferedImage object. If the BufferedImage object is null we then are putting the key + a null into the CACHE.
- myk
- Posts: 439
- Joined: 17 Jan 2013, 02:39
- Location: California
- Has thanked: 38 times
- Been thanked: 57 times
Re: Bug Reports (snapshot builds)
by Chris H. » 20 Mar 2013, 16:58
myk wrote:A note on this -- if we cache an image (null, or a default) when the file is not found, then newly downloaded images may not show up until Forge is reloaded. On the other hand, if a file is not found once, it is likely to not be found again. How about if we clear the cache after any GuiDownloader run so new images show up properly, yet we prevent hammering the file system looking for missing files?
Sounds like a good idea.
-
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: Bug Reports (snapshot builds)
by myk » 20 Mar 2013, 22:20
Was this implemented? I notice there are now errors after import because of files being left behind, which all seem to be flip cards. Remember that any changes to how cards are mapped to images will require corresponding changes to the MigrationSourceAnalyzer class. If there are images that will not be needed in the new code (such as the alternate sides of flip cards, if that is what we want), add them to the cruftFile list at FView:165 so they get deleted.Max mtg wrote:I suggest to download a single image and filp these cards programmatically.
- myk
- Posts: 439
- Joined: 17 Jan 2013, 02:39
- Location: California
- Has thanked: 38 times
- Been thanked: 57 times
Re: Bug Reports (snapshot builds)
by Max mtg » 20 Mar 2013, 22:46
Ok, myk, if both CCGHQ and Wizards provide separate pictures for flipped cards, let's just use them.
Commited 20510 - that's the only change needed.
Have looked though a fewcards... Marc has hosted their fliped pictures, fine then, good to use them.
Commited 20510 - that's the only change needed.
Have looked though a fewcards... Marc has hosted their fliped pictures, fine then, good to use them.
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: Bug Reports (snapshot builds)
by myk » 20 Mar 2013, 23:54
Cool, thx. I just implemented flipping of the flippable cards in VPicture and VDetail too, so now both sides can be seen and examined.
- myk
- Posts: 439
- Joined: 17 Jan 2013, 02:39
- Location: California
- Has thanked: 38 times
- Been thanked: 57 times
Re: Bug Reports (snapshot builds)
by swordshine » 21 Mar 2013, 01:51
I cannot start a match since r20488, quite weird.
- swordshine
- Posts: 682
- Joined: 11 Jul 2010, 02:37
- Has thanked: 116 times
- Been thanked: 87 times
Re: Bug Reports (snapshot builds)
by goonjamin » 21 Mar 2013, 02:07
What kind of match are you trying to start? I just played a 2 colour random constructed game without issue here on r20515.swordshine wrote:I cannot start a match since r20488, quite weird.
Re: Bug Reports (snapshot builds)
by swordshine » 21 Mar 2013, 04:58
I updated java version to java7, and it worked in r20488-20491(my local version using Java6 cannot pass r20488). But in r20492, I could start a game again. Maybe some of my local preferences files are broken and I don't know how to restore them.swordshine wrote:I cannot start a match since r20488, quite weird.
- swordshine
- Posts: 682
- Joined: 11 Jul 2010, 02:37
- Has thanked: 116 times
- Been thanked: 87 times
Re: Bug Reports (snapshot builds)
by Chris H. » 21 Mar 2013, 11:44
swordshine wrote:I updated java version to java7, and it worked in r20488-20491(my local version using Java6 cannot pass r20488). But in r20492, I could start a game again. Maybe some of my local preferences files are broken and I don't know how to restore them.swordshine wrote:I cannot start a match since r20488, quite weird.
Our user data has been moved to a new location recently.
- Code: Select all
For reference, here is the full list of moved directories:
Old location New location
---------------- ----------------------
res/decks/ <userDir>/decks/
res/gauntlet/ <userDir>/gauntlet/
res/layouts/ <userDir>/preferences/
res/preferences/ <userDir>/preferences/
res/quest/data/ <userDir>/quest/saves/
res/pics/ <cacheDir>/pics/
My <userDir>/preferences/ directory contains these four files:
editor.preferences
editor.xml
forge.preferences
match.xml
I would guess that the last one might be what you are looking for. You could try moving the /preferences/ dir out of the <userDir> dir and then restart forge. forge might detect the missing /preferences/ dir and would write the missing files into the missing /preferences/ dir.
If this works you might then be able to move the first three files back into the /preferences/ dir and this would then give you back your settings for these three files.
-
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: Bug Reports (snapshot builds)
by swordshine » 21 Mar 2013, 12:09
Thanks Chris, I recreated a local version of forge and it works now.
- swordshine
- Posts: 682
- Joined: 11 Jul 2010, 02:37
- Has thanked: 116 times
- Been thanked: 87 times
Re: Bug Reports (snapshot builds)
by friarsol » 22 Mar 2013, 02:26
r20535
When casting Painter's Servant after choosing the color as it ETB I get this crash:
java.lang.RuntimeException: CardUtil : getShortColor() invalid argument - ChosenColor
at forge.CardUtil.getShortColor(CardUtil.java:56)
at forge.CardUtil.getShortColorsString(CardUtil.java:77)
at forge.StaticEffects.removeStaticEffect(StaticEffects.java:156)
at forge.StaticEffects.clearStaticEffects(StaticEffects.java:63)
at forge.game.GameAction.checkStaticAbilities(GameAction.java:873)
at forge.game.GameAction.checkStateEffects(GameAction.java:948)
at forge.game.zone.MagicStack.finishResolving(MagicStack.java:984)
When casting Painter's Servant after choosing the color as it ETB I get this crash:
java.lang.RuntimeException: CardUtil : getShortColor() invalid argument - ChosenColor
at forge.CardUtil.getShortColor(CardUtil.java:56)
at forge.CardUtil.getShortColorsString(CardUtil.java:77)
at forge.StaticEffects.removeStaticEffect(StaticEffects.java:156)
at forge.StaticEffects.clearStaticEffects(StaticEffects.java:63)
at forge.game.GameAction.checkStaticAbilities(GameAction.java:873)
at forge.game.GameAction.checkStateEffects(GameAction.java:948)
at forge.game.zone.MagicStack.finishResolving(MagicStack.java:984)
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Bug Reports (snapshot builds)
by sidereal » 22 Mar 2013, 03:56
I had the same problem at HEAD after having my data migrated. I ran it through the debugger and found it was crashing in ImageCache's static initialization when it tries to load up the default image (no_card.jpg). There's a catch there for IOException but it actually throws an IllegalArgumentException if it can't find it. Might be worth catching Exception there instead so it doesn't just silently kill the thread. I'm not sure why it isn't finding no_card.jpg. It's in my resources. For now I'm just logging the exception and ignoring it. Here's the stack trace:swordshine wrote:I cannot start a match since r20488, quite weird.
- Code: Select all
java.lang.IllegalArgumentException: input == null!
at javax.imageio.ImageIO.read(ImageIO.java:1322)
at forge.ImageCache.<clinit>(ImageCache.java:80)
at forge.gui.match.CMatchUI.getPlayerAvatar(CMatchUI.java:59)
at forge.gui.match.CMatchUI.initMatch(CMatchUI.java:107)
Re: Bug Reports (snapshot builds)
by storms » 22 Mar 2013, 18:56
when ai use lord of the void ability forge crashes often
angel of serenity ability when she is removed from the field sometimes it causes forge to hang and when u push ok nothing happens
angel of serenity ability when she is removed from the field sometimes it causes forge to hang and when u push ok nothing happens
- storms
- Posts: 10
- Joined: 12 Jan 2013, 20:42
- Has thanked: 0 time
- Been thanked: 0 time
Re: Bug Reports (snapshot builds)
by 7543021 » 23 Mar 2013, 01:42
Painter's Servant seems don’t effect your hand zone.I want him to combo with Chandra Ablaze.My Painter's Servant on the field(naming red),but activating Chandra Ablaze 's +1ability didn't deal any damage unless you discard a card that is original red.I'm using forge r20541.
- 7543021
- Posts: 14
- Joined: 16 Feb 2013, 08:54
- Has thanked: 0 time
- Been thanked: 0 time
Who is online
Users browsing this forum: No registered users and 16 guests