Пример #1
0
        public void myPengBtnClick()
        {
            MyHandCardView.isPutout = true;
            _tableView.resetTimer();
            CardVO cvo = new CardVO();

            cvo.cardPoint = _data.putoutPoint;
            GameManager.getInstance().Server.requset(APIS.PENGPAI_REQUEST, JsonMapper.ToJson(cvo));
            _actionHlpr.cleanBtnShow();
        }
Пример #2
0
        /**客户端主动打一只牌**/
        public void putoutCard(int cardPoint)         //
        {
            _data.paiArray [0] [cardPoint]--;
            _data.putoutIndex = _data.myIndex;
            _data.putoutPoint = cardPoint;
            createPutOutCardAndPlayAction(_data.putoutPoint, _data.putoutIndex);
            //========================================================================
            CardVO cvo = new CardVO();

            cvo.cardPoint = cardPoint;
            GameManager.getInstance().Server.requset(APIS.CHUPAI_REQUEST, JsonMapper.ToJson(cvo));
        }
Пример #3
0
        public void myChiBtnClick()
        {
            MyHandCardView.isPutout = true;
            MyHandCardView.isChi    = false;
            _tableView.resetTimer();
            CardVO cvo = new CardVO();

            cvo.cardPoint = _data.putoutPoint;
            cvo.onePoint  = _data.chiPoints[0];
            cvo.twoPoint  = _data.chiPoints[1];
            GameManager.getInstance().Server.requset(APIS.CHIPAI_REQUEST, JsonMapper.ToJson(cvo));
            _actionHlpr.cleanBtnShow();
        }
Пример #4
0
        public void onMyPickCard(ClientResponse response)
        {
            _tableView.resetTimer();
            CardVO cardvo    = JsonMapper.ToObject <CardVO> (response.message);
            int    cardPoint = cardvo.cardPoint;

            _data.pickIndex = _data.myIndex;
            _data.pickPoint = cardPoint;
            _data.paiArray [0] [cardPoint]++;
            _uiHelper.addPickCard(_data.pickIndex, _data.pickPoint);
            _uiHelper.updateRemainCardNum();
            MyHandCardView.isPutout = true;
        }
Пример #5
0
        /**
         * 胡牌请求
         */
        public void myHuBtnClick()
        {
            if (_data.huCardPoint != -1)
            {
                CardVO cvo = new CardVO();
                cvo.cardPoint = _data.huCardPoint;

                if (_data.isQiangHu)
                {
                    cvo.type        = "qianghu";
                    _data.isQiangHu = false;
                }
                string sendMsg = JsonMapper.ToJson(cvo);
                GameManager.getInstance().Server.requset(APIS.HUPAI_REQUEST, sendMsg);
                _actionHlpr.cleanBtnShow();
            }
        }
Пример #6
0
 public ChiRequest(CardVO cardvo)
 {
     headCode       = APIS.CHI_REQUEST;
     messageContent = JsonMapper.ToJson(cardvo);
 }
Пример #7
0
 public PutOutCardRequest(CardVO cardvo)
 {
     headCode       = APIS.CHUPAI_REQUEST;
     messageContent = JsonMapper.ToJson(cardvo);
     ;
 }
Пример #8
0
 public PengCardRequest(CardVO cardvo)
 {
     headCode       = APIS.PENGPAI_REQUEST;
     messageContent = JsonMapper.ToJson(cardvo);
 }
Пример #9
0
 public CheatRequest(CardVO cardvo)
 {
     headCode       = APIS.CHEAT_Request;
     messageContent = JsonMapper.ToJson(cardvo);
 }