It is currently 07 Sep 2025, 00:10
   
Text Size

Developing Bugs

Post MTG Forge Related Programming Questions Here

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

Re: Developing Bugs

Postby Sloth » 19 Oct 2012, 21:10

When i have the choice of playing first ot drawing and choose draw, i also get to play first.

When i concede the game (by clicking x) nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: Developing Bugs

Postby friarsol » 19 Oct 2012, 21:39

I won a Quest game and that's reported correctly on the screen, but the WinLose Screen says I lost my ante and the card I ante'd is shown. After the second game, it showed I won the match and now that I won the ante. Looking at my card pool after the game, the card I anted in the first game is missing.

Additionally, the AI starts playing before I even finish mulliganing.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Developing Bugs

Postby Max mtg » 20 Oct 2012, 06:57

Sloth wrote:When i have the choice of playing first ot drawing and choose draw, i also get to play first.
Fixed

Sloth wrote:When i concede the game (by clicking x) nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
Could not reproduce
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: Developing Bugs

Postby friarsol » 20 Oct 2012, 13:51

Regarding the Mulligan thing I mentioned below, it looks like I'm in Main1 when I start mulliganing too, which means the game isn't waiting for the mulligan input to finish before starting the game phases.

Additionally, the Declare Blockers/Declare Attackers Phase Icons aren't lit up when I'm in the play instants/abilities portion of that phase.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Developing Bugs

Postby Sloth » 20 Oct 2012, 14:38

Max mtg wrote:
Sloth wrote:When i concede the game (by clicking x) nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
Could not reproduce
Ups, forgot a step:
When i concede the game (by clicking x) and click "Restart" nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: Developing Bugs

Postby ArsenalNut » 20 Oct 2012, 15:12

Sloth wrote:
Max mtg wrote:
Sloth wrote:When i concede the game (by clicking x) nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
Could not reproduce
Ups, forgot a step:
When i concede the game (by clicking x) and click "Restart" nothing happens. When i click x again i get this error:
| Open
Code: Select all
java.lang.NullPointerException
   at forge.gui.match.ViewWinLose.<init>(ViewWinLose.java:115)
   at forge.GameAction.checkStateEffects(GameAction.java:1012)
   at forge.gui.match.controllers.CDock.concede(CDock.java:71)
   at forge.control.FControl$2.windowClosing(FControl.java:117)
I am getting something similar. When I play a constructed match to completion, hitting the restart button does not restart the match. I have to hit quit to go back to the main menu.
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: Developing Bugs

Postby Max mtg » 20 Oct 2012, 16:10

r17599 - fixed restart problem (new game did not start after pressing 'restart')
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: Developing Bugs

Postby Max mtg » 20 Oct 2012, 19:43

Phase icons are lit properly now.
As for mulligan, I didn't reproduce it. (AI has turn and does not advance behind Untap) Made a change to code that might help.
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: Developing Bugs

Postby friarsol » 20 Oct 2012, 20:09

Max mtg wrote:As for mulligan, I didn't reproduce it. (AI has turn and does not advance behind Untap) Made a change to code that might help.
Does anyone else see this? I don't have any local changes right now and here's the screenshot of the AI with a land already played while I have a prompt to Mulligan. This is just in a quick constructed match.

http://imgur.com/xTIlk
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Developing Bugs

Postby Sloth » 20 Oct 2012, 21:53

Using r17606 i get this when i start a game:
| Open
java.lang.NullPointerException
at forge.game.phase.PhaseUtil.visuallyActivatePhase(PhaseUtil.java:347)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:537)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.game.zone.Zone.update(Zone.java:334)
at forge.game.zone.PlayerZone.add(PlayerZone.java:106)
at forge.game.zone.Zone.add(Zone.java:116)
at forge.game.GameNew.prepareSingleLibrary(GameNew.java:68)
at forge.game.GameNew.newGame(GameNew.java:127)
at forge.game.MatchController.startRound(MatchController.java:125)
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: Developing Bugs

Postby Max mtg » 20 Oct 2012, 22:17

Sloth wrote:Using r17606 i get this when i start a game:
| Open
java.lang.NullPointerException
at forge.game.phase.PhaseUtil.visuallyActivatePhase(PhaseUtil.java:347)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:537)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.GameLog.add(GameLog.java:61)
at forge.game.phase.PhaseHandler.nextPhase(PhaseHandler.java:528)
at forge.util.MyObservable.updateObservers(MyObservable.java:49)
at forge.game.zone.Zone.update(Zone.java:334)
at forge.game.zone.PlayerZone.add(PlayerZone.java:106)
at forge.game.zone.Zone.add(Zone.java:116)
at forge.game.GameNew.prepareSingleLibrary(GameNew.java:68)
at forge.game.GameNew.newGame(GameNew.java:127)
at forge.game.MatchController.startRound(MatchController.java:125)
Oh, sh.t!
This comes from r17605... have to figure out where I have broken it.
For your convinience I rolled back changes from that revision.
Last edited by Max mtg on 20 Oct 2012, 22:20, edited 1 time in total.
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: Developing Bugs

Postby Doublestrike » 20 Oct 2012, 22:18

I get that too...also, for the last two days:

| Open
Read decks: 254 constructed, 1 sealed, 0 draft, 3 cubes.
java.lang.NullPointerException
at forge.Card.determineColor(Card.java:1736)
at forge.CardUtil.getColors(CardUtil.java:151)
at forge.gui.GuiDisplayUtil.getBorder(GuiDisplayUtil.java:81)
at forge.gui.CardDetailPanel.setCard(CardDetailPanel.java:158)
at forge.gui.match.controllers.CDetail.showCard(CDetail.java:51)
at forge.gui.deckeditor.CDeckEditorUI.setCard(CDeckEditorUI.java:53)
at forge.gui.deckeditor.tables.EditorTableModel.showSelectedCard(EditorTableModel.java:193)
at forge.gui.deckeditor.tables.EditorTableModel$1.valueChanged(EditorTableModel.java:216)
at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:167)
at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:147)
at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:194)
at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:388)
at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:398)
at javax.swing.DefaultListSelectionModel.setSelectionInterval(DefaultListSelectionModel.java:442)
at javax.swing.JTable.changeSelectionModel(JTable.java:2352)
at javax.swing.JTable.changeSelection(JTable.java:2421)
at javax.swing.plaf.basic.BasicTableUI$Handler.adjustSelection(BasicTableUI.java:1085)
at javax.swing.plaf.basic.BasicTableUI$Handler.mousePressed(BasicTableUI.java:1008)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:263)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:262)
at java.awt.Component.processMouseEvent(Component.java:6285)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
at java.awt.Component.processEvent(Component.java:6053)
at java.awt.Container.processEvent(Container.java:2041)
at java.awt.Component.dispatchEventImpl(Component.java:4651)
at java.awt.Container.dispatchEventImpl(Container.java:2099)
at java.awt.Component.dispatchEvent(Component.java:4481)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4577)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4235)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
at java.awt.Container.dispatchEventImpl(Container.java:2085)
at java.awt.Window.dispatchEventImpl(Window.java:2478)
at java.awt.Component.dispatchEvent(Component.java:4481)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:643)
at java.awt.EventQueue.access$000(EventQueue.java:84)
at java.awt.EventQueue$1.run(EventQueue.java:602)
at java.awt.EventQueue$1.run(EventQueue.java:600)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
at java.awt.EventQueue$2.run(EventQueue.java:616)
at java.awt.EventQueue$2.run(EventQueue.java:614)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:613)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
java.lang.NullPointerException
at forge.Card.determineColor(Card.java:1736)
at forge.CardUtil.getColors(CardUtil.java:151)
at forge.gui.GuiDisplayUtil.getBorder(GuiDisplayUtil.java:81)
at forge.gui.CardDetailPanel.setCard(CardDetailPanel.java:158)
at forge.gui.match.controllers.CDetail.showCard(CDetail.java:51)
at forge.gui.deckeditor.CDeckEditorUI.setCard(CDeckEditorUI.java:53)
at forge.gui.deckeditor.tables.EditorTableModel.showSelectedCard(EditorTableModel.java:193)
at forge.gui.deckeditor.tables.EditorTableModel$2.focusGained(EditorTableModel.java:227)
at java.awt.AWTEventMulticaster.focusGained(AWTEventMulticaster.java:203)
at java.awt.Component.processFocusEvent(Component.java:6177)
at java.awt.Component.processEvent(Component.java:6044)
at java.awt.Container.processEvent(Container.java:2041)
at java.awt.Component.dispatchEventImpl(Component.java:4651)
at java.awt.Container.dispatchEventImpl(Container.java:2099)
at java.awt.Component.dispatchEvent(Component.java:4481)
at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1850)
at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:901)
at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:513)
at java.awt.Component.dispatchEventImpl(Component.java:4523)
at java.awt.Container.dispatchEventImpl(Container.java:2099)
at java.awt.Window.dispatchEventImpl(Window.java:2478)
at java.awt.Component.dispatchEvent(Component.java:4481)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:643)
at java.awt.EventQueue.access$000(EventQueue.java:84)
at java.awt.EventQueue$1.run(EventQueue.java:602)
at java.awt.EventQueue$1.run(EventQueue.java:600)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
at java.awt.EventQueue$2.run(EventQueue.java:616)
at java.awt.EventQueue$2.run(EventQueue.java:614)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:613)
at java.awt.SequencedEvent.dispatch(SequencedEvent.java:101)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:641)
at java.awt.EventQueue.access$000(EventQueue.java:84)
at java.awt.EventQueue$1.run(EventQueue.java:602)
at java.awt.EventQueue$1.run(EventQueue.java:600)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
at java.awt.EventQueue$2.run(EventQueue.java:616)
at java.awt.EventQueue$2.run(EventQueue.java:614)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:613)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:178)
at java.awt.Dialog$1.run(Dialog.java:1046)
at java.awt.Dialog$3.run(Dialog.java:1098)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Dialog.show(Dialog.java:1096)
at java.awt.Component.show(Component.java:1584)
at java.awt.Component.setVisible(Component.java:1536)
at java.awt.Window.setVisible(Window.java:842)
at java.awt.Dialog.setVisible(Dialog.java:986)
at forge.error.ErrorViewer.showDialog(ErrorViewer.java:192)
at forge.error.ErrorViewer.showError(ErrorViewer.java:117)
at forge.error.ErrorViewer.showError(ErrorViewer.java:79)
at forge.error.ExceptionHandler.handle(ExceptionHandler.java:62)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at java.awt.EventDispatchThread.handleException(EventDispatchThread.java:385)
at java.awt.EventDispatchThread.processException(EventDispatchThread.java:291)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:285)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
---
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: Developing Bugs

Postby Doublestrike » 20 Oct 2012, 22:18

...where's the "delete post" button?...
Last edited by Doublestrike on 20 Oct 2012, 22:24, edited 2 times in total.
---
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: Developing Bugs

Postby Max mtg » 20 Oct 2012, 22:21

That's my faulty commit - you should update to 17607 where changes from 17605 were rolled back

I'll move my broken version to a branch and investigate there
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: Developing Bugs

Postby friarsol » 20 Oct 2012, 23:11

In Quest Mode, pets/plants aren't resetting when starting a new game. In one game, my hound pet was tapped (to start a game). In another it didn't have summoning sickness. I've noticed some oddities where the AI kills it in the second game, it's no longer on the BF, but the card image still shows it being on the BF.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 53 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 53 users online :: 0 registered, 0 hidden and 53 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 53 guests

Login Form