How to integrate networking with Slick?

Hey guys I am just starting to use Slick for programming a 2D game in Java. My game needs to have networking support for multiple players over a LAN but I am not sure how to integrate this with Slick.

I have simple networking code that is basically like a chatserver that intercepts messages and broadcast them to the connected clients.

All I want to do is create a simple demo that creates a sprite for each client connected and then the image moves based on messages received from the server.
For testing and to start out I am trying to take Spiegel’s simple game tutorial and make it multiplayer.
http://slick.cokeandcode.com/wiki/doku.php?id=01_-_a_basic_slick_game

Below is a screenshot of what i am trying to make multiplayer. The local user would be able to move his sprite around while the remote user’s sprite will be updated according to messages received from the server.

(credit to Spiegel)

If anyone has a link to a tutorial or source code that I could look at to accomplish this then I would greatly appreciate it. Also, I think something simple like this would be good for other people trying to use networking with Slick.

Hi

I would suggest taking a look at Java Game Networking:
http://forum.captiveimagination.com/index.php/board,4.0.html

It’s a very easy to use networking api and you can use it with Slick (or any other rendering api)

Here’s a simple test project I made with JGN and Java2D:
http://www.mediafire.com/?ymn0du2tyyt

Thanks for the info and the demo!

I will definitely look into JGN.

EDIT: Ok looks like JGN is supportive of JME so now I would like to know how to integrate JGN with Slick.
Looking at the JGN examples with JME I realize that I do not know enough about JME or Slick to be able to
change the example to work with Slick, anyone have any ideas?

See my response on the JGN forums. The synchronization system should make it really easy to support Slick. There is already a GTGE-Synchronization implementation (GTGE is another 2D Java game framework) and you should be able to just change a few things to rig it up with Slick instead.