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

World generator plugin issues #27

Closed
PAndaContron opened this issue Oct 27, 2018 · 1 comment · Fixed by #29
Closed

World generator plugin issues #27

PAndaContron opened this issue Oct 27, 2018 · 1 comment · Fixed by #29

Comments

@PAndaContron
Copy link
Contributor

PAndaContron commented Oct 27, 2018

It seems like a few of the world generators don't function properly because of their lakes being added as plugins. This is probably because everyone followed the tutorial where lakes were implemented this way. This leads to issues where the lakes from one generator interfere with another, causing crashes or hangs.

The "I'm getting thirsty" and "Lava Land" generators crash with the following error:

java.lang.RuntimeException: Cannot set a changed component with a null component variable
        at org.terasology.persistence.internal.EntityDelta.setChangedComponent(EntityDelta.java:34)
        at org.terasology.persistence.internal.EntitySetDeltaRecorder.onEntityComponentChange(EntitySetDeltaRecorder.java:70)
        at org.terasology.persistence.internal.EntitySetDeltaRecorder.onEntityComponentAdded(EntitySetDeltaRecorder.java:61)
        at org.terasology.persistence.internal.ReadWriteStorageManager.onEntityComponentAdded(ReadWriteStorageManager.java:528)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.notifyComponentAdded(PojoEntityManager.java:704)
        at org.terasology.entitySystem.entity.internal.PojoEntityManager.addComponent(PojoEntityManager.java:539)
        at org.terasology.entitySystem.entity.internal.BaseEntityRef.addComponent(BaseEntityRef.java:167)
        at org.terasology.engine.modes.loadProcesses.CreateWorldEntity.step(CreateWorldEntity.java:102)
        at org.terasology.engine.modes.StateLoading.update(StateLoading.java:243)
        at org.terasology.engine.TerasologyEngine.tick(TerasologyEngine.java:458)
        at org.terasology.engine.TerasologyEngine.mainLoop(TerasologyEngine.java:421)
        at org.terasology.engine.TerasologyEngine.run(TerasologyEngine.java:397)
        at org.terasology.engine.Terasology.main(Terasology.java:155)

Additionally, world generators outside of this module which use plugins will hang indefinitely while trying to load the lakes from "TropikGenerator", printing this stacktrace to console over and over:

java.lang.NullPointerException: null
        at org.terasology.additionalworlds.imgettingthirsty.LakesRasterizer.generateChunk(LakesRasterizer.java:43)
        at org.terasology.world.generation.WorldImpl.rasterizeChunk(WorldImpl.java:64)
        at org.terasology.world.generation.BaseFacetedWorldGenerator.createChunk(BaseFacetedWorldGenerator.java:75)
        at org.terasology.world.chunks.localChunkProvider.LocalChunkProvider$1.run(LocalChunkProvider.java:657)
        at org.terasology.utilities.concurrency.TaskProcessor.run(TaskProcessor.java:50)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)

This issue could be fixed simply by changing the implementations of lakes in every generator to use regular Providers and Rasterizers rather than plugins.

@PAndaContron
Copy link
Contributor Author

The "I'm getting thirsty" generator seems to have another issue in it with the MountainsProvider configuration which causes the same error. The lakes plugin is most likely still causing an error though, since the Lake Rasterizer and Provider seem to be identical to the classes in Lava Land, where they do cause an error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant