package com.game;

import com.game.data.Player;
import com.taurus.core.entity.ITObject;
import com.taurus.permanent.data.Session;

/**
 * 网络路由处理
 * 
 */
public abstract class Router {
	/**
	 *  删除房间
	 */
    public static final String GAME_REMOVE_ROOM = "1000";
	/**
	 *  更新GPS位置
	 */
	public static final String GAME_UPDATE_POS = "1001";
	/**
	 *  更新GPS位置事件
	 */
	public static final String GAME_EVT_UPDATE_POS = "2000";
	/**
	 *  进入房
	 */
    public static final String GAME_JOIN_ROOM = "1002";
    /**
     *  玩家进入房间
     */
    public static final String GAME_EVT_PLAYER_JOIN = "2001";
    /**
     *  玩家退出
     */
    public static final String GAME_EVT_PLAYER_EXIT = "2002";
    /**
     *  玩家网络状态
     */
    public static final String GAME_EVT_PLAYER_NET_STATE = "2003";
    /**
     *  发送聊天
     */
    public static final String GAME_INTERACTION = "1006";
    /**
     *  聊天事件
     */
    public static final String GAME_EVT_INTERACTION = "2017";
    /**
     *  退出房间
     */
    public static final String GAME_EXIT_ROOM = "1005";
    /**
     *  房主退出房间解散
     */
    public static final String GAME_EVT_EXIT_ROOM_DISMISS = "2008";

    /**
     *  发送准备
     */
    public static final String GAME_READY = "1003";

    /**
     *  发送准备加洗牌
     */
    public static final String GAME_READY_AND_XIPAI = "201004";

    /**
     * 准备加洗牌 返回
     */
    public static final String GAME_EVT_READY_AND_XIPAI = "202009";

    /**
     *  准备事件
     */
    public static final String GAME_EVT_READY = "2009";

    /**
     *  通知托管倒计时
     */
    public static final String GAME_EVT_READY_ENTRUST = "22010";
    public static final String GAME_EVT_CANCEL_READY_ENTRUST = "22011";


    public static final String  GAME_XIPAI			= "20836";

    public static final String  GAME_EVENT_XIPAI			= "20837";

    public static final String  GAME_EVENT_NOTIFY_XIPAI			= "20838";

    /**
     *  请求开始游戏
     */
    public static final String GAME_START = "1004";
    /**
     *  请求解散房间
     */
    public static final String GAME_ASK_DISMISS_ROOM = "1007";
    /**
     *  解散房间
     */
    public static final String GAME_EVT_DISMISS_ROOM = "2005";
    /**
     *  请求解散房间投票
     */
    public static final String GAME_DISMISS_ROOM_VOTE = "1008";
    /**
     *  解散房间投票事件
     */
    public static final String GAME_EVT_DISMISS_ROOM_VOTE = "2006";
    /**
     *  解散房间失败
     */
    public static final String GAME_EVT_DISMISS_ROOM_FAIL= "2027";
    /**
     * 
     */
    public static final String GAME_EVT_SEND_REDPACKET= "3000";
    /**
     * 玩家被退出
     */
    public static final String GAME_EVT_KICK_PLAYER= "3001";
    
    /**
     * 玩家缺体力值弹起
     */
    public static final String GAME_EVT_STAND_UP= "3004";
    
    /**
     * 托管
     */
    public static final String GAME_ENTRUST= "1301";
    /**
     * 入座
     */
    public static final String GAME_JOIN_SEAT= "1302";
    /**
     * 自动
     */
    public static final String GAME_AUTO_CARD = "1303";

    /**
     * 玩家进入观众席
     */
    public static final String GAME_EVT_JOIN_SPECTATOR= "3002";
    
	/**
     * 更新玩家信息
     */
    public static final String GAME_EVT_UPDATE_PLAYERINFO= "3003";

    /**
     *  客户端数据出错，需要重连服务器，更新关键数据
     */
    public static final String GAME_EVT__UPDATE_RECONECT = "3005";
    
	public void handel(Session sender, ITObject params, int gid){
		
	}

	public abstract void handelRoom(Player owner, ITObject params, int gid);
}
