I’m getting both a ConcurrentModifierException and a NullpointerException which forces the world to save and quit upon a player logging in. I’ve done a ton of debugging, but I can’t seem to find out whats going on other than a null pointer in ChunkBuilder line 78.
Thing is, the classes that provide the data for ChunkBuilder to do its stuff on (VolcanicSystem and VeinSystem) should never provide it with a null pointer.
Solution
made sure all added points were converted to chunk coordinates
Changed all HashMaps to Hashtables.
No null pointers or concurrent modifier exceptions atm. This has illuminated other worrying behavior though.
Not by default, from what I can tell, you’re making several unions of the key sets, which isn’t isolating that set any from the other internal sets (basically, you want to make a new set to return and just addAll or whatever functionality you need to do on that new set, not on the key sets you’re using). BlockInformation itself isn’t very “safe” in that regard since it leaks all sorts of references to it’s own internal map.
Thats weird. there’s no setter for field: block, and the constructor requires a string param.
I think? I fixed it. It seems like the null pointer was related to something else. ConcurrentModifier error was fixed by changing my HashMaps to Hashtables. I’m gonna go ahead and call this one ‘solved’, but there is still some runtime behavior that is worrying. I’ll put it in another thread.