Search code examples
javaandroidnetworkingkryokryonet

KryoNet - Sending packets to Android clients


I am developing an Android app which has to connect clients to my server for sending/receiving different sort of packets. To achieve that, I am using the KryoNet library. My clients connect themself to the server and send their own packets successfully. But my problem is that the server seems to failed at responding to them. I have registered these packets in the same order on the server side and the client side and I use the connection parameter of the overrided reveived method from kryonet.Listener to respond (e.g. connection.sendUDP(...)). I have an Android 5.0.2, I use the 2.22.0-RC1 version of KryoNet both on the server side and the client side... With the option Log.set(Log.LEVEL_DEBUG) enabled, I can see that the server starts to write a packet (DEBUG: [kryo] write: PacketMovement) but I receive nothing.

I would really appreciate any help on this issue.


Solution

  • The answer for people having the same problem : https://github.com/EsotericSoftware/kryonet/pull/111.