public void DoResultCodeDelegation(NFMsg.EGameEventCode code, String data)
 {
     if (mhtEventDelegation.ContainsKey(code))
     {
         ResultCodeDelegation myDelegationHandler = (ResultCodeDelegation)mhtEventDelegation[code];
         myDelegationHandler(code, "");
     }
 }
Esempio n. 2
0
        private void EGMI_EVENT_RESULT(NFMsg.MsgBase xMsg)
        {
            //OnResultMsg
            NFMsg.AckEventResult xResultCode = new NFMsg.AckEventResult();
            xResultCode = mxSerializer.Deserialize(new MemoryStream(xMsg.msg_data), null, typeof(NFMsg.AckEventResult)) as NFMsg.AckEventResult;
            NFMsg.EGameEventCode eEvent = xResultCode.event_code;

            mxNetListener.DoResultCodeDelegation(eEvent);
        }
Esempio n. 3
0
        private void EGMI_EVENT_RESULT(MsgHead head, MemoryStream stream)
        {
            //OnResultMsg
            NFMsg.AckEventResult xResultCode = new NFMsg.AckEventResult();
            xResultCode = Serializer.Deserialize <NFMsg.AckEventResult>(stream);
            NFMsg.EGameEventCode eEvent = xResultCode.event_code;

            mNet.mxBinMsgEvent.DoResultCodeDelegation(eEvent);
        }
        private void EGMI_EVENT_RESULT(int id, MemoryStream stream)
        {
            NFMsg.MsgBase xMsg = NFMsg.MsgBase.Parser.ParseFrom(stream);

            //OnResultMsg
            NFMsg.AckEventResult xResultCode = NFMsg.AckEventResult.Parser.ParseFrom(xMsg.MsgData);
            NFMsg.EGameEventCode eEvent      = xResultCode.EventCode;

            DoResultCodeDelegation(eEvent, "");
        }
Esempio n. 5
0
        public bool DoResultCodeDelegation(NFMsg.EGameEventCode eCode)
        {
            if (mhtEventDelegation.ContainsKey(eCode))
            {
                ResultCodeDelegation myDelegationHandler = (ResultCodeDelegation)mhtEventDelegation[eCode];
                myDelegationHandler(eCode);

                return(true);
            }

            return(false);
        }
 public void AddMsgEventCallBack(NFMsg.EGameEventCode code, NFNetHandlerModule.ResultCodeDelegation netHandler)
 {
     if (!mhtEventDelegation.ContainsKey(code))
     {
         ResultCodeDelegation myDelegationHandler = new ResultCodeDelegation(netHandler);
         mhtEventDelegation.Add(code, myDelegationHandler);
     }
     else
     {
         ResultCodeDelegation myDelegationHandler = (ResultCodeDelegation)mhtEventDelegation[code];
         myDelegationHandler += new ResultCodeDelegation(netHandler);
     }
 }
Esempio n. 7
0
        public bool RegisteredResultCodeDelegation(NFMsg.EGameEventCode eCode, ResultCodeDelegation msgDelegate)
        {
            if (!mhtEventDelegation.ContainsKey(eCode))
            {
                ResultCodeDelegation myDelegationHandler = new ResultCodeDelegation(msgDelegate);
                mhtEventDelegation.Add(eCode, myDelegationHandler);
            }
            else
            {
                ResultCodeDelegation myDelegationHandler = (ResultCodeDelegation)mhtMsgDelegation[eCode];
                myDelegationHandler += new ResultCodeDelegation(msgDelegate);
            }

            return(true);
        }
Esempio n. 8
0
 private void EGEC_ACCOUNT_SUCCESS(NFMsg.EGameEventCode eCode)
 {
 }
Esempio n. 9
0
 private void EGEC_UNKOWN_ERROR(NFMsg.EGameEventCode eCode)
 {
 }
Esempio n. 10
0
 private void EGEC_ACCOUNT_SUCCESS(NFMsg.EGameEventCode eCode)
 {
     mNet.mPlayerState = NFNet.PLAYER_STATE.E_HAS_PLAYER_LOGIN;
 }
Esempio n. 11
0
 private void EGEC_ENTER_GAME_SUCCESS(NFMsg.EGameEventCode eCode)
 {
     mNet.mPlayerState = NFNet.PLAYER_STATE.E_PLAYER_GAMEING;
 }