Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.49-DEV-StratCon - Saving and reloading game causes hostile contacts in AtB Campaign State to become nonresponsive #2517

Closed
EmmaEmmaEmma2 opened this issue Apr 14, 2021 · 3 comments
Labels
Bug Needs Investigation This issue needs investigation and/or triage. StratCon Bugs relating strictly to StratCon
Milestone

Comments

@EmmaEmmaEmma2
Copy link

Environment

StratCon alpha test build (MekHQ CI with Gradle #1168: Pull request #2144)
Windows 10
OpenJDK 11.0.10

Midnight comes again
Game is saved, time for slumber
Hostile contacts broke

Description

Possibly related to #2512?
In my current save, if you advance the day, generate new hostile contacts on the AtB Campaign State tab, save the game, and reload the save, the generated hostile contacts become non-interactive (can't click on the hex, can't right click, etc). Initiating the scenario before the save/reload functions as expected and generates a scenario in the Briefing Room. I noticed also that though previously newly generated hostile contacts would show in the Command Center, the contacts generated in my save game don't show any notification.

Tangentially related, while trying to reproduce the bug so I could write this report, I was somehow able to create a scenario with a resolution date of 1 day in the past, which MekHQ wouldn't let me initiate. I wasn't able to reproduce the bug, but if I do I'll write up a separate report for it.

Files

Included both pre and post bug saves (8/23 and 8/24 respectively)
Campaign Info.zip
mekhqlog.txt

@sixlettervariables sixlettervariables added this to the StratCon milestone Apr 14, 2021
@sixlettervariables sixlettervariables added Bug Needs Investigation This issue needs investigation and/or triage. StratCon Bugs relating strictly to StratCon labels Apr 14, 2021
@sixlettervariables
Copy link
Contributor

Error from log:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at mekhq.campaign.stratcon.StratconScenario.getInfo(StratconScenario.java:165)
	at mekhq.campaign.stratcon.StratconScenario.getInfo(StratconScenario.java:154)
	at mekhq.gui.stratcon.StratconScenarioWizard.setInstructions(StratconScenarioWizard.java:152)
	at mekhq.gui.stratcon.StratconScenarioWizard.setUI(StratconScenarioWizard.java:105)
	at mekhq.gui.stratcon.StratconScenarioWizard.setCurrentScenario(StratconScenarioWizard.java:90)
	at mekhq.gui.StratconPanel.actionPerformed(StratconPanel.java:650)
	at java.desktop/javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1967)
	at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2308)
	at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:405)
	at java.desktop/javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:262)
	at java.desktop/javax.swing.AbstractButton.doClick(AbstractButton.java:369)
	at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1020)
	at java.desktop/javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:1064)
	at java.desktop/java.awt.Component.processMouseEvent(Component.java:6635)
	at java.desktop/javax.swing.JComponent.processMouseEvent(JComponent.java:3342)
	at java.desktop/java.awt.Component.processEvent(Component.java:6400)
	at java.desktop/java.awt.Container.processEvent(Container.java:2263)
	at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5011)
	at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321)
	at java.desktop/java.awt.Component.dispatchEvent(Component.java:4843)
	at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4918)
	at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4547)
	at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4488)
	at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2307)
	at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2772)
	at java.desktop/java.awt.Component.dispatchEvent(Component.java:4843)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:772)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95)
	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:745)
	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:743)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

@NickAragua
Copy link
Member

Looks like the issue is that, under independent command, the dynamic AtB scenario underlying the StratCon scenario doesn't get registered with the campaign until after you commit the primary force to it.

@NickAragua
Copy link
Member

Fixed with 0c8de94

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Needs Investigation This issue needs investigation and/or triage. StratCon Bugs relating strictly to StratCon
Projects
None yet
Development

No branches or pull requests

3 participants