It is currently 04 Sep 2025, 10:39
   
Text Size

Error when using NEW UI setting in the latest version 07-16

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins

Error when using NEW UI setting in the latest version 07-16

Postby zaroblan » 02 Aug 2010, 15:04

I cannot use the New UI setting, the application throws up an exception trace and then eventually dies. I am running the latest Java runtime under Windows 7 (I am a local administrator)

Thanks again for an awesome product and keep up the amazing work guys.
zaroblan
 
Posts: 59
Joined: 22 May 2009, 11:36
Has thanked: 0 time
Been thanked: 0 time

Re: Error when using NEW UI setting in the latest version 07

Postby zaroblan » 02 Aug 2010, 15:05

Sorry the attachment got dropped somehow. Here is the dump:


An error has occured. You can copy/paste this message or save it to a file.
Please report this, plus what you tried to do, to:
viewforum.php?f=26
If you don't want to register an account, you can mail it directly to
mtgerror@yahoo.com


null


Version:
Forge -- official beta: $Date: 2010-05-01 03:21:42 -0400 (Sat, 01 May 2010) $, SVN revision: $Revision: 916 $

OS: Windows 7 Version: 6.1 Architecture: x86

Java Version: 1.6.0_20 Vendor: Sun Microsystems Inc.

Detailed error trace:
java.lang.NullPointerException
at arcane.ui.CardPanel.paintChildren(CardPanel.java:180)
at javax.swing.JComponent.paint(Unknown Source)
at arcane.ui.CardPanel.paint(CardPanel.java:158)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at org.jdesktop.swingx.JXMultiSplitPane.paintChildren(JXMultiSplitPane.java:298)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JLayeredPane.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paintToOffscreen(Unknown Source)
at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at java.awt.Window.paint(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
zaroblan
 
Posts: 59
Joined: 22 May 2009, 11:36
Has thanked: 0 time
Been thanked: 0 time

Re: Error when using NEW UI setting in the latest version 07

Postby DennisBergkamp » 02 Aug 2010, 15:35

Strange... does the same thing happen with the 07-31 beta?
Code: Select all
if (showCastingCost && !isAnimationPanel && cardWidth < 200) {
This is the line where it breaks, showCastingCost might not have been initialized? Then again, isn't an uninitialized boolean set to false?
User avatar
DennisBergkamp
AI Programmer
 
Posts: 2602
Joined: 09 Sep 2008, 15:46
Has thanked: 0 time
Been thanked: 0 time

Re: Error when using NEW UI setting in the latest version 07

Postby Snacko » 02 Aug 2010, 16:45

Primitive data types in Java cannot be null. So that error can't happen on this line according to Java specification.
Snacko
DEVELOPER
 
Posts: 826
Joined: 29 May 2008, 19:35
Has thanked: 4 times
Been thanked: 74 times

Re: Error when using NEW UI setting in the latest version 07

Postby mtgrares » 03 Aug 2010, 18:29

class A
{
int a;
boolean b;
}

In a new object:

a is initialized to 0
b is initialized to false
mtgrares
DEVELOPER
 
Posts: 1352
Joined: 08 Sep 2008, 22:10
Has thanked: 3 times
Been thanked: 12 times

Re: Error when using NEW UI setting in the latest version 07

Postby DennisBergkamp » 03 Aug 2010, 18:35

Yeah, so what's going wrong? It doesn't make sense #-o
User avatar
DennisBergkamp
AI Programmer
 
Posts: 2602
Joined: 09 Sep 2008, 15:46
Has thanked: 0 time
Been thanked: 0 time

Re: Error when using NEW UI setting in the latest version 07

Postby Rob Cashwalker » 03 Aug 2010, 18:45

but what if you do this:

A myAObject = null;
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: Error when using NEW UI setting in the latest version 07

Postby DennisBergkamp » 03 Aug 2010, 19:12

Right, but these are not objects, they're primitive data types.
User avatar
DennisBergkamp
AI Programmer
 
Posts: 2602
Joined: 09 Sep 2008, 15:46
Has thanked: 0 time
Been thanked: 0 time

Re: Error when using NEW UI setting in the latest version 07

Postby Rob Cashwalker » 03 Aug 2010, 19:17

but what if the object they were a member of was null? We often create placeholder objects that will be assigned at a later point, but in the meantime, to make the compiler happy about initializing objects, they're set to null.
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


Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 69 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 69 users online :: 0 registered, 0 hidden and 69 guests (based on users active over the past 10 minutes)
Most users ever online was 7303 on 15 Jul 2025, 20:46

Users browsing this forum: No registered users and 69 guests

Login Form