Package server.common

Examples of server.common.GameException


        Message response = null;
        try {
            // Try to create a new player acount
            response = game.newAccount(pl_name, pl_pwd);
            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here


        try {
            // Try to log the current player
            response = game.login(pl_name, pl_pwd);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to log the current player
            response = game.logout(pl_id);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to create a new game for the current player
            response = game.createNewPlay(playerID);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to create a new game for the current anonymous player
            response = game.createNewAnonymPlay(pl_id);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to load the plays list for the current player
            response = game.loadPlayList(playerID);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to load an existed play for the current player
            response = game.loadSavedPlay(playerID, playID);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to save current play for the current player
            response = game.SavePlay(type, playerID, playID, ga_infos);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Try to delete an existed play for the current anonymous player
            response = game.deleteAnonym(playerID);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

        try {
            // Check if the player's game is correct.
            response = game.checkGame(playerID, playID, gameInfos);

            if (response == null) {
                throw new GameException(GameException.typeErr.SYSKO);
            }
        } catch (GameException e) {
            response = processError(e);
        }
        return response;
View Full Code Here

TOP

Related Classes of server.common.GameException

Copyright © 2018 www.massapicom. 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.