It is currently 07 Nov 2025, 22:41
   
Text Size

UI Improvements, Round 3: Home Screen

Post MTG Forge Related Programming Questions Here

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

Re: UI Improvements, Round 3: Home Screen

Postby Doublestrike » 21 Jan 2012, 09:44

Big day of work on the skins. All of the symbols are now consolidated into the default skin, and will be accessible for use shortly. The images need to be improved for quality, since the originals were really small.

Also, the feature where a missing part of a skin is replaced with the default is now implemented.

This has led to sprites that can be very simple, such as the "smith" sprite - just a color swatch, and default values are used automatically. So, skins are even easier to make now. I've included the grid in the default skin for reference only.

The skin now loads with the preloader also. I'll be putting in better descriptions of what's happening in the preloader tonight or tomorrow (probably).

Oh, also, everything is now accessible via an enum, which is (obviously) better form than the strings :oops:

That Rebel skin looks really good!!!! :supz: And the Dark Ascension too - it certainly adds to the depth of the Forge experience. :)
---
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: UI Improvements, Round 3: Home Screen

Postby Doublestrike » 22 Jan 2012, 01:29

FProgressBar is up and working. It's a less complex version of the previous, touchy-license one, and should be far, far easier to use.

The actual architecture of card loading has not changed, only the messages have been updated. There's some interesting details now when it starts up, users can now see where the time goes and why.

I'm fairly sure thread safety has been addressed properly, but will be checking here for any weird bugs.

EDIT - FSkin is still running on the EDT so the progress bar updates chunk-ily. Known bug, will be fixed.
---
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: UI Improvements, Round 3: Home Screen

Postby Hellfish » 22 Jan 2012, 10:54

Posting here because I think this occurs while creating the home screen:
Since r13399 this NPE has been thrown for me when "Creating display components" according to the progress bar:
Code: Select all
java.lang.NullPointerException
   at forge.control.home.ControlQuest.addListeners(ControlQuest.java:87)
   at forge.control.home.ControlQuest.<init>(ControlQuest.java:83)
   at forge.view.home.ViewQuest.<init>(ViewQuest.java:128)
   at forge.view.home.HomeTopLevel.<init>(HomeTopLevel.java:71)
   at forge.control.FControl.changeState(FControl.java:141)
   at forge.view.FView$3.run(FView.java:120)
   at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251)
   at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:705)
   at java.awt.EventQueue.access$000(EventQueue.java:101)
   at java.awt.EventQueue$3.run(EventQueue.java:666)
   at java.awt.EventQueue$3.run(EventQueue.java:664)
   at java.security.AccessController.doPrivileged(Native Method)
   at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
   at java.awt.EventQueue.dispatchEvent(EventQueue.java:675)
   at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:211)
   at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
   at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
   at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
   at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
   at java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

I can't continue after this,sadly. :S
So now you're
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
User avatar
Hellfish
Programmer
 
Posts: 1297
Joined: 07 Jun 2009, 10:41
Location: South of the Pumphouse
Has thanked: 110 times
Been thanked: 169 times

Re: UI Improvements, Round 3: Home Screen

Postby Doublestrike » 22 Jan 2012, 11:16

@Hellfish - odd, works fine for me, every time. Apparently returning null on the getBtnStart() method. This is a new method, maybe there's a conflict or an SVN/Eclipse problem?
---
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: UI Improvements, Round 3: Home Screen

Postby Hellfish » 22 Jan 2012, 12:03

It happens on a clean checkout too,with all available skins. :/
I wish I could give more useful info but I'm in way over my head..
So now you're
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
User avatar
Hellfish
Programmer
 
Posts: 1297
Joined: 07 Jun 2009, 10:41
Location: South of the Pumphouse
Has thanked: 110 times
Been thanked: 169 times

Re: UI Improvements, Round 3: Home Screen

Postby Chris H. » 22 Jan 2012, 12:08

Doublestrike wrote:I'm fairly sure thread safety has been addressed properly, but will be checking here for any weird bugs.
`
I will edit the changes.txt file and will add this good news as a new fluff piece. :D
User avatar
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: UI Improvements, Round 3: Home Screen

Postby Sloth » 22 Jan 2012, 12:15

When i start the game and immediately start a match i'm not in dev mode (even though it's checked in the preferences). When i quit and start another match i'm in dev mode.

When i start the game and switch dev mode off and on again and then start my first match i'm in dev mode.
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: UI Improvements, Round 3: Home Screen

Postby Chris H. » 22 Jan 2012, 13:13

I am getting the same error as Hellfish. I will attach the report as mine appears to be slightly different.

I will not be able to release a snapshot and apologize to everyone.

Crash Report | Open
This is a Crash Report. An error has occurred. Please save this message to a file.
Please follow the instructions at this address to submit this Crash Report, plus what you were doing at the time:
http://tinyurl.com/3zzrnyb
Reporting bugs in Forge is very important. We thank you for your time.

null


Version:
Forge version SVN

OS: Mac OS X Version: 10.7.2 Architecture: x86_64

Java Version: 1.6.0_29 Vendor: Apple Inc.

Detailed error trace:
java.lang.NullPointerException
at forge.control.home.ControlQuest.addListeners(ControlQuest.java:87)
at forge.control.home.ControlQuest.<init>(ControlQuest.java:83)
at forge.view.home.ViewQuest.<init>(ViewQuest.java:128)
at forge.view.home.HomeTopLevel.<init>(HomeTopLevel.java:71)
at forge.control.FControl.changeState(FControl.java:141)
at forge.view.FView$3.run(FView.java:120)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:677)
at java.awt.EventQueue.access$000(EventQueue.java:85)
at java.awt.EventQueue$1.run(EventQueue.java:638)
at java.awt.EventQueue$1.run(EventQueue.java:636)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:647)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
User avatar
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: UI Improvements, Round 3: Home Screen

Postby Hellfish » 22 Jan 2012, 14:57

I think I found it. :D
ViewQuest.btnStart is instantiated in ViewQuest.populateStartArea() which isn't called unless the user has a questdata file present, which is not the case with a clean checkout. I don't know how to best fix it in accordance with your grand plan ( ;) ) but in the meantime, have a quest file if you suffer this same problem.
Attachments
questData.zip
(17.05 KiB) Downloaded 178 times
So now you're
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
User avatar
Hellfish
Programmer
 
Posts: 1297
Joined: 07 Jun 2009, 10:41
Location: South of the Pumphouse
Has thanked: 110 times
Been thanked: 169 times

Re: UI Improvements, Round 3: Home Screen

Postby Chris H. » 22 Jan 2012, 15:35

Hellfish wrote:I think I found it. :D
ViewQuest.btnStart is instantiated in ViewQuest.populateStartArea() which isn't called unless the user has a questdata file present, which is not the case with a clean checkout. I don't know how to best fix it in accordance with your grand plan ( ;) ) but in the meantime, have a quest file if you suffer this same problem.
`
I downloaded the file, added it to my local forge project, refreshed and ran the project. Same error on my end.
User avatar
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: UI Improvements, Round 3: Home Screen

Postby Chris H. » 22 Jan 2012, 16:30

Chris H. wrote:I downloaded the file, added it to my local forge project, refreshed and ran the project. Same error on my end.
`
I figured out what happened on my end. I double clicked on your questData.zip file and my OS unzipped this to a questData.dat file and then unzipped it again and I ended up with a unzipped file named questData :mrgreen:

No wonder it did not stop the crash report. I moved a copy of a questData.dat file from elsewhere on my computer over to my local copy of the project and this time it ran without the crash report.
User avatar
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: UI Improvements, Round 3: Home Screen

Postby slapshot5 » 23 Jan 2012, 01:28

Sloth wrote:When i start the game and immediately start a match i'm not in dev mode (even though it's checked in the preferences). When i quit and start another match i'm in dev mode.

When i start the game and switch dev mode off and on again and then start my first match i'm in dev mode.
Yeah, same here.

-slapshot5
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

Re: UI Improvements, Round 3: Home Screen

Postby ArsenalNut » 23 Jan 2012, 04:08

slapshot5 wrote:
Sloth wrote:When i start the game and immediately start a match i'm not in dev mode (even though it's checked in the preferences). When i quit and start another match i'm in dev mode.

When i start the game and switch dev mode off and on again and then start my first match i'm in dev mode.
Yeah, same here.

-slapshot5
I think you are in the Dev mode the first match but dev panel isn't displayed. I ran a test deck with only two cards and didn't get a loss when I had to draw. Still pretty useless to be in dev mode without the panel though.
So many cards, so little time
User avatar
ArsenalNut
 
Posts: 512
Joined: 08 Jul 2011, 03:49
Has thanked: 27 times
Been thanked: 121 times

Re: UI Improvements, Round 3: Home Screen

Postby Doublestrike » 24 Jan 2012, 00:40

peeps wrote:Dev mode bug
I'll fix this later tonight after work (~10 hours).

Not sure if people have been following the dev log, but there was a hodgepodge of settings that was not in accordance with the MVC/singleton architecture. Understandably, people had just been patching in whatever worked at the time, and it was a bit nutso in the top level classes.

So, I've been sorting stuff out, consolidating and clarifying. Apparently the dev mode bug is a casualty of this. Slipped through testing, but I'll have it sorted soon.

If someone wants to have a crack first, the problem is Constant.Runtime.DEV_MODE[0] is not being set when the forge preferences are loaded and/or toggled.

Probably a one-line fix, most likely in forge.view.home.ViewSettings.java (don't have the code in front of me but that's probably it). The other likely culprit is the loadPreferences() method in forge.view.GuiTopLevel (this method should be in the model, but it's legacy from the old UI).

Detective Hellfish wrote:Quest data bug
Thanks! Will fix that later too.
---
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: UI Improvements, Round 3: Home Screen

Postby slapshot5 » 24 Jan 2012, 04:40

Something else that has changed rather recently (and I apologize if this is known; I didn't see a post about it anywhere):

Whenever I start Forge, it starts in a small size, like 800x600. Then I drag it to make it bigger on the Home screen, and it stays big for my match. Then Exit. Next time I run Forge, I'm back to the 800x600. Drag to make it bigger... rinse, wash, repeat.

-slapshot5
slapshot5
Programmer
 
Posts: 1391
Joined: 03 Jan 2010, 17:47
Location: Mac OS X
Has thanked: 25 times
Been thanked: 68 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 90 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 90 users online :: 0 registered, 0 hidden and 90 guests (based on users active over the past 10 minutes)
Most users ever online was 9298 on 10 Oct 2025, 12:54

Users browsing this forum: No registered users and 90 guests

Login Form