using FL.Data.Items; using FL.Network; using System; using XGame; using XGame.Framework.Data; using XGame.Framework.Network; namespace FL.Data { public class DragonEggService : DataSingleton, IDisposable { /// /// 请求(龙蛋)宝藏信息 /// public void SendToTreasureInfo() { IMsgRequest msg = new LongdanIntoRequest() { }; NetModule.Request(msg); } /// /// 请求开启龙蛋宝藏 /// public void SendToOpenDragonTreasure(int itemId, int count) { // 向服务器发送开启龙蛋宝藏消息 IMsgRequest msg = new LongdanOpenRequest() { itemid = itemId, count = count }; NetModule.Request(msg); } /// /// 领取宝箱进度奖励 /// public void SendToOpenTreasureBoxAward() { NetModule.Request(new LongdanRwdBoxRequest(){ }); } /// /// 请求龙蛋升级 /// public void SendToUpgrade() { NetModule.Request(new LongdanUpLevelRequest() { }); } /// /// 请求加速宝箱升级 /// /// 1_加速 2_广告 /// 使用数量type=1有效 public void SendToAcceleration(int type, int useNum) { var msg = new LongdanSubcdRequest() { type = type, count = useNum }; NetModule.Request(msg); } /// /// 请求替换装备 /// /// /// public void OnChangeEquip(long id) { var msg = new EquipTihuanRequest() { xhid = (int)id }; NetModule.Request(msg); } /// /// 出售指定的装备 /// /// public void SellEquip(int[] sellIds) { var msg = new EquipDelEquipRequest() { xhids = sellIds }; NetModule.Request(msg); } /// /// 一键出售装备背包中的所有装备 /// public void SendToSellAllBagEquips() { NetModule.Request(new EquipDelEquipLsRequest() { }); } /// /// 请求装备临时背包数据 /// public void SendToOpenTemporaryEquipBag() { NetModule.Request(new EquipIntoLsRequest() { }); } void IDisposable.Dispose() { } } }