Neop / mudmap2

A mapping tool for text-based games, like text adventures, MUDs and MUSHs
42 stars 12 forks source link

Error when opening a world file with 2.4.3 #5

Closed AsyrDFC closed 7 years ago

AsyrDFC commented 7 years ago
Jun 04, 2017 6:11:25 PM mudmap2.frontend.dialog.OpenWorldDialog create
WARNING: null
java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.valueOf(Unknown Source)
        at java.lang.Integer.decode(Unknown Source)
        at mudmap2.backend.WorldFileReader.current.WorldFileJSON.hexToCol(WorldF
ileJSON.java:434)
        at mudmap2.backend.WorldFileReader.current.WorldFileJSON.readFile(WorldF
ileJSON.java:228)
        at mudmap2.backend.WorldFileReader.current.WorldFileDefault.readFile(Wor
ldFileDefault.java:97)
        at mudmap2.backend.WorldManager.getWorld(WorldManager.java:58)
        at mudmap2.frontend.dialog.OpenWorldDialog.create(OpenWorldDialog.java:8
5)
        at mudmap2.frontend.dialog.OpenWorldDialog.actionPerformed(OpenWorldDial
og.java:106)
        at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
        at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
        at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
        at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
        at javax.swing.AbstractButton.doClick(Unknown Source)
        at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
        at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown
Source)
        at java.awt.Component.processMouseEvent(Unknown Source)
        at javax.swing.JComponent.processMouseEvent(Unknown Source)
        at java.awt.Component.processEvent(Unknown Source)
        at java.awt.Container.processEvent(Unknown Source)
        at java.awt.Component.dispatchEventImpl(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Window.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
        at java.awt.EventQueue.access$500(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
rivilege(Unknown Source)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
rivilege(Unknown Source)
        at java.awt.EventQueue$4.run(Unknown Source)
        at java.awt.EventQueue$4.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
rivilege(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)

Hello. I've been using MUD Map 2.4.3 for a few days now (it's been awesome, by the way) -- but I recently ran into an issue when trying to open a world file -- here is what it throws back at me when trying to do so. I have other saved world files which open fine, except for this one in particular.

Neop commented 7 years ago

Thanks for your bug report, I'll take a look at it in the next few days. I'm sorry that this inconvenience happened.

Neop commented 7 years ago

A color entry in your world file seems to be invalid. I fixed MUD Map so it replaces the missing color by a grey tone. I'm not sure how that invalid entry got into your file, my only explanation is that you removed a color or something related to a color and MUD Map tried to save this removed object (null). I could not find the original cause but made the program a bit more reliable by adding this default color (grey) in case of invalid colors. I hope this solves your problem. https://github.com/Neop/mudmap2/releases/tag/v2.4.4