mathew.er
April 16th, 2006, 08:41 AM
Hi,
I now find myself in need of a socket server made with Java.
Just to let you know what I need to do... Im creating a multi-agent simulation in Java and I want a Flash client to be able to view the progress of the simulation. Flash is going to recieve only information about agents (position and other properties) and probbably send some information (some additional agent info requests).
I have this (http://www.gotoandplay.it/_articles/2003/12/xmlSocket.php) example. Its supersimple server. I have no idea how to continue. If I close the running .swf file, it ends the server app. I need it to keep running. My idea how it could work is to: Listen for connections, handle incoming connections (pass them to some manager to keep track of them) and add some functionality to react on clients requests and broadcast messages.
Im not too well familiar with Java and sometimes its just giving me headaches.
Do you have an ideas, pointer where and how to continue?
btw. I have noticed that it sends message from server only when it recieves one. Does it allways have to be like that?
I now find myself in need of a socket server made with Java.
Just to let you know what I need to do... Im creating a multi-agent simulation in Java and I want a Flash client to be able to view the progress of the simulation. Flash is going to recieve only information about agents (position and other properties) and probbably send some information (some additional agent info requests).
I have this (http://www.gotoandplay.it/_articles/2003/12/xmlSocket.php) example. Its supersimple server. I have no idea how to continue. If I close the running .swf file, it ends the server app. I need it to keep running. My idea how it could work is to: Listen for connections, handle incoming connections (pass them to some manager to keep track of them) and add some functionality to react on clients requests and broadcast messages.
Im not too well familiar with Java and sometimes its just giving me headaches.
Do you have an ideas, pointer where and how to continue?
btw. I have noticed that it sends message from server only when it recieves one. Does it allways have to be like that?