try{
core = Core.getInstance(null);
serverSocket = new ServerSocket(cEworldEventServer.port);
assignedPort = serverSocket.getLocalPort();
SocketConnection socketConnection = new SocketConnection();
socketConnection.success = true;
socketConnection.port = assignedPort;
Gson gson = new Gson();
String json = gson.toJson(socketConnection, SocketConnection.class);