Beispiel #1
0
    /// <summary>
    /// 购买材料
    /// </summary>
    void OnClickBuyMeterial()
    {
        CG_ASK_YUANBAOSHOP_OPEN packet = (CG_ASK_YUANBAOSHOP_OPEN)PacketDistributed.CreatePacket(MessageID.PACKET_CG_ASK_YUANBAOSHOP_OPEN);

        packet.NoParam = (int)YuanBaoShopLogic.OPEN_TYPE.OPEN_CHRISTMAS;
        packet.SendPacket();
    }
    void OnBuyClick()
    {
        CG_ASK_YUANBAOSHOP_OPEN packet = (CG_ASK_YUANBAOSHOP_OPEN)PacketDistributed.CreatePacket(MessageID.PACKET_CG_ASK_YUANBAOSHOP_OPEN);

        packet.NoParam = (int)YuanBaoShopLogic.OPEN_TYPE.OPEN_FESTIVAL;
        packet.SendPacket();
    }
    public void OnClickBuy()
    {
        CG_ASK_YUANBAOSHOP_OPEN packet = (CG_ASK_YUANBAOSHOP_OPEN)PacketDistributed.CreatePacket(MessageID.PACKET_CG_ASK_YUANBAOSHOP_OPEN);

        packet.NoParam = (int)YuanBaoShopLogic.OPEN_TYPE.OPEN_FLOWEREGG;
        packet.SendPacket();
    }
        public uint Execute(PacketDistributed ipacket)
        {
            CG_ASK_YUANBAOSHOP_OPEN packet = (CG_ASK_YUANBAOSHOP_OPEN )ipacket;

            if (null == packet)
            {
                return((uint)PACKET_EXE.PACKET_EXE_ERROR);
            }
            //enter your logic
            return((uint)PACKET_EXE.PACKET_EXE_CONTINUE);
        }
    public void OnOpenShop()
    {
        if (m_bOpening)
        {
            return;
        }

        CG_ASK_YUANBAOSHOP_OPEN packet = (CG_ASK_YUANBAOSHOP_OPEN)PacketDistributed.CreatePacket(MessageID.PACKET_CG_ASK_YUANBAOSHOP_OPEN);

        packet.NoParam = (int)YuanBaoShopLogic.OPEN_TYPE.OPEN_FUNCTION_BUTTON;
        packet.SendPacket();
    }