Open keturn opened 4 years ago
probably worth noting that I was on this server for a bit before I got this error, but after that I don't think was able to successfully re-join without running in to this immediately.
The line that encounters the null is NetComponentSerializeCheck: https://github.com/MovingBlocks/Terasology/blob/3815d963df90f9a16d65617c17ef635a2d817f86/engine/src/main/java/org/terasology/network/serialization/NetComponentSerializeCheck.java#L30-L31
so one option would be to add a null check there and return a constant default.
but I don't want to paper over symptoms if they're a sign of a deeper problem. Should that parameter be nullable at all?
IntelliJ IDEA thinks that a null in that spot most likely comes from here: https://github.com/MovingBlocks/Terasology/blob/8840b62d8f3402db71c214225e82ffabe70b5e20/engine/src/main/java/org/terasology/reflection/metadata/AbstractClassLibrary.java#L104-L106
that null check has been there forever.
I'm not sure what it would mean to have a null there. Does object.getClass() ever return null in java?
Curious to get some thoughts from @eviltak on this issue. Not really wanting to paper symptoms over either, but on the other hand the entirety of the netcode probably really needs a bit of an overhaul sometime in the future, maybe as part of hooking up multiplayer for DS via shared lib then re-integrating the newer Gestalt pieces back into TS.
@skaldarnar
this is not Object.getClass return null
, but custom mapping.
There used idTable
as mapping between Component
's Type and id
for networking.
similar code used for Event
's Types
It looks like desyncronization between client and server by ComponentType's ids. (may be we have some code, which add/remove component types, or not cleaned ids after previous game)
What you were trying to do
join the playtest server during the fallingblocks + volcano test
What actually happened