I never used KryoNet in anger so I may be misinterpreting stuff, but
here's my interpretation of the error:
The error is this:
--
Caused by: com.esotericsoftware.kryo.KryoException:
java.lang.ClassCastException: my.game.components.TilePositionComponent
cannot be cast to com.badlogic.gdx.math.Vector3
Serialization trace:
oldTilePosition (my.game.components.SpriteComponent)
components (my.game.networking.NetworkEntity)
networkEntities (my.game.networking.GameState)
gameState (my.game.networking.messages.GameStateMsg)
--
I.e. it is getting a my.game.components.TilePositionComponent where it
required a com.badlogic.gdx.math.Vector3.
The serialization trace looks like it is deserializing the
oldTilePosition of a SpriteComponent, expected a TilePositionComponent
but got a Vector3 instead.
The typical cause would be that client and server disagree about the
type of oldTilePosition. This wouldn't matter as long as oldTilePosition
is null, and trigger as soon as a non-null oldTilePosition is
transferred. This might explain the seemingly random behaviour.
Entirely unrelated: I see
Writing 1024x256: res\pack\game.png
in the output. In the Java world, it is strongly recommended to use / in
all pathnames unless you're talking directly to the filesystem, or to
some external software that expects a platform-formatted pathname
string. Please ask a search engine for details, this message is too long
already :-)
HTH
Jo