Fixed some bugs and update engine

This commit is contained in:
Light2
2013-07-08 12:53:42 +02:00
parent 5756ec02ca
commit 9e8eea30a1
6 changed files with 19 additions and 3 deletions
+13
View File
@@ -264,6 +264,19 @@ public class NGECore {
return connections;
}
public int getActiveZoneClients() {
int connections = 0;
for (Map.Entry<Integer, Client> c : clients.entrySet()) {
if(c.getValue().getSession() != null) {
if (c.getValue().getSession().isConnected() && c.getValue().getParent() != null) {
connections++;
}
}
}
return connections;
}
public Client getClient(int connectionID) {
return clients.get(connectionID);
}