@Override
	public void run() {
		try {
			selector.selectNow();
			for (SelectionKey selectionKey : selector.selectedKeys()) {
				if (selectionKey.isAcceptable()) {
					accept(); // Accept a new connection.
				}
				if (selectionKey.isReadable()) {
					sessionMap.get(selectionKey).incomingCycle();
				}
			}
		} catch (Exception ex) {
			ex.printStackTrace();
		}
		try {
			WorldUpdater.getWorldUpdater().run();
		} catch (Exception ex) {
			ex.printStackTrace();
		}
	}