Examples of LobbyServer


Examples of net.yura.lobby.server.LobbyServer

            ServerMode serverMode = new ServerMode();
            serverMode.setBlocking(false);

            Server myServer = new Server();
            myServer.lobbyServer = new LobbyServer(myServer);

            //myServer.findFirstClientById(null); // username
            //myServer.findClientByKey(null); // uuid

            //QuickServerConfig config = new QuickServerConfig();
View Full Code Here

Examples of net.yura.lobby.server.LobbyServer

public class BinaryHandler implements ClientBinaryHandler {

    @Override
    public void handleBinary(ClientHandler ch, byte[] bytes) throws SocketTimeoutException, IOException {

        LobbyServer server = ((Server)ch.getServer()).lobbyServer;
        Session cd = (Session)ch.getClientData();
        cd.data.addBytes(bytes);
       
        while (true) {
            if (cd.size==-1 && cd.data.available() >= 4) {
                cd.size = cd.data.readInt();
            }
            else if (cd.size>=0 && cd.data.available() >= cd.size) {
                Message message = server.decode(cd.data, cd.size);
                cd.size = -1;
                handleMessage(ch, message);
            }
            else {
                break;
View Full Code Here

Examples of net.yura.lobby.server.LobbyServer

        }
    }
   
    private void handleMessage(ClientHandler ch, Message message) {
       
        LobbyServer server = ((Server)ch.getServer()).lobbyServer;
        LobbySession session = ((Session)ch.getClientData()).lobbySession;
       
        server.handleMessage(session,message);
    }
View Full Code Here

Examples of net.yura.lobby.server.LobbyServer

    private final LobbyServer server;

    public Server(int port) {
        this.port = port;

        server = new LobbyServer(this);

        bossGroup = new NioEventLoopGroup();
        workerGroup = new NioEventLoopGroup();

        if (DEBUG_SEND) {
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.