tchegito / zildo

The Land of Alembrume
GNU Lesser General Public License v3.0
4 stars 1 forks source link

[2.54] scene can't be found #164

Closed tchegito closed 5 years ago

tchegito commented 5 years ago
version=v2.54
map=null
sprites=[]
persos=[]
special=We have an additional failure here !java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.Map zildo.server.state.ScriptManagement.getVariables()' on a null object reference
    at zildo.fwk.net.www.CrashReporter.addContext(CrashReporter.java:37)
    at com.alembrum.OpenGLRenderer.onDrawFrame(OpenGLRenderer.java:113)
    at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1571)
    at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1270)
java.lang.RuntimeException: Scene setup doesn't exist !
    at zildo.server.state.ScriptManagement.execute(ScriptManagement.java:175)
    at zildo.server.state.ScriptManagement.execute(ScriptManagement.java:161)
    at zildo.server.state.ScriptManagement.(ScriptManagement.java:122)
    at zildo.server.EngineZildo.initializeServer(EngineZildo.java:85)
    at zildo.server.EngineZildo.(EngineZildo.java:121)
    at zildo.client.stage.SinglePlayer.(SinglePlayer.java:79)
    at zildo.client.gui.menu.SaveGameMenu.loadGameFromBuffer(SaveGameMenu.java:176)
    at zildo.client.gui.menu.SaveGameMenu.loadGame(SaveGameMenu.java:169)
    at zildo.client.gui.menu.SaveGameMenu.access$3(SaveGameMenu.java:166)
    at zildo.client.gui.menu.SaveGameMenu$2.run(SaveGameMenu.java:110)
    at zildo.client.Client.mainLoop(Client.java:242)
    at com.alembrum.OpenGLRenderer.onDrawFrame(OpenGLRenderer.java:110)
    at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1571)
    at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1270)

Maybe game was started before all XML was fully loaded ? Maybe an issue from the new way of loading scripts, with multi-threading.

tchegito commented 5 years ago

[Fixed in 2.55]

Probably caused by the multithreading. Actually, just the creation of fixedThreadPool creates 5 thread. So, as we're not really needing that feature, we can stick to a simple sequential load.

9fd7588b52fdbab3c9588fc8574d63f7636b28c8