package org.pollux3d.server;
import java.io.IOException;
import com.jme3.network.connection.Client;
import com.jme3.network.connection.Server;
import com.jme3.network.events.ConnectionListener;
public class DedicatedPolluxServer implements ConnectionListener {
private Server server;
public DedicatedPolluxServer() {
try {
server = new Server(5110, 5110);
} catch (IOException e) {
e.printStackTrace();
}
}
public boolean start() {
try {
server.start();
return true;
} catch (IOException e) {
e.printStackTrace();
}
return false;
}
public static void main(String[] args) {
DedicatedPolluxServer server = new DedicatedPolluxServer();
server.start();
}
public void clientConnected(Client client) {
System.out.println("Con: " + client.getClientID());
}
public void clientDisconnected(Client client) {
System.out.println("Discon: " + client.getClientID());
}
}