Examples of PlayerReceivedMessageEvent


Examples of org.ggp.base.player.event.PlayerReceivedMessageEvent

        String in = HttpReader.readAsServer(connection);
        if (in.length() == 0) {
            throw new IOException("Empty message received.");
        }

        notifyObservers(new PlayerReceivedMessageEvent(in));
        GamerLogger.log("GamePlayer", "[Received at " + System.currentTimeMillis() + "] " + in, GamerLogger.LOG_LEVEL_DATA_DUMP);

        Request request = new RequestFactory().create(gamer, in);
        String out = request.process(System.currentTimeMillis());
View Full Code Here

Examples of org.ggp.base.player.event.PlayerReceivedMessageEvent

          // First, read a message from the server.
        ProxyMessage nextMessage = inputQueue.take();
        Socket connection = inputConnectionQueue.take();
        String in = nextMessage.theMessage;
        long receptionTime = nextMessage.receptionTime;
        notifyObservers(new PlayerReceivedMessageEvent(in));
        GamerLogger.log("Proxy", "[PROXY] Got incoming message:" + in);

        // Formulate a request, and see how the legal gamer responds.
        String legalProxiedResponse;
        Request request = new RequestFactory().create(theDefaultGamer, in);
View Full Code Here

Examples of org.ggp.base.player.event.PlayerReceivedMessageEvent

          ProxyMessage theMessage = ProxyMessage.readFrom(theInput);
          GamerLogger.log("Proxy", "[ProxyClient] Got message: " + theMessage);
          String in = theMessage.theMessage;
          theCode = theMessage.messageCode;
          long receptionTime = theMessage.receptionTime;
        notifyObservers(new PlayerReceivedMessageEvent(in));

        Request request = new RequestFactory().create(gamer, in);
        if(request instanceof StartRequest) {
            RandomGamer theDefaultGamer = new RandomGamer();
            new RequestFactory().create(theDefaultGamer, in).process(1);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.