Beispiel #1
0
        private void buttonUpdatePetTaskState_Click(object sender, EventArgs e)
        {
            UInt32 petTaskIndex = 0;

            UnityGMClient.ETaskState state = UnityGMClient.ETaskState.ETASKSTATE_ACCEPT;
            UInt16 curCount = 0;

            try
            {
                petTaskIndex = UInt32.Parse(textBoxPara1.Text);
                state        = (UnityGMClient.ETaskState)UInt32.Parse(textBoxPara2.Text);
                curCount     = (UInt16)UInt32.Parse(textBoxPara3.Text);
            }
            catch (System.Exception)
            {
                MessageBox.Show("数据输入错误! ", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            UnityGMClient.CClientCore.Singleton.SendMsgTaskSystemGC2GMReqUpdatePetTaskState(petTaskIndex, state, curCount,
                                                                                            delegate(UnityGMClient.EUpdatePetTaskStateResult result, UInt32 taskIndex, UnityGMClient.ETaskState newState, UInt16 count)
            {
                string resultStr = string.Format("更新状态返回[{0}], taskIndex[{1}], state[{2} curCount[{3}]]", result, taskIndex, newState, count);
                textBoxTips.Text = textBoxTips.Text + resultStr + "\r\n";
            });
        }
Beispiel #2
0
 void cbMsgGM2GCNtfMainTaskState(UInt32 mainTaskTPID, UnityGMClient.ETaskState state, UInt32 curCount)
 {
     GC.CLog.write("cbMsgGM2GCNtfMainTaskState");
 }