From bf08bbbfbd0ed3258c609b02873e590b4a4f12f2 Mon Sep 17 00:00:00 2001 From: sk <123456@qq.com> Date: Mon, 15 Jul 2024 17:12:05 +0800 Subject: [PATCH] =?UTF-8?q?=E8=8E=B7=E5=BE=97=E9=81=93=E5=85=B7=E8=AE=B0?= =?UTF-8?q?=E5=BD=95=E6=B6=88=E8=80=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- worldsrv/action_phonelottery.go | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/worldsrv/action_phonelottery.go b/worldsrv/action_phonelottery.go index 7be5ed1..fd63987 100644 --- a/worldsrv/action_phonelottery.go +++ b/worldsrv/action_phonelottery.go @@ -389,7 +389,23 @@ func (this *CSDiamondLotteryHandler) Process(s *netlib.Session, packetid int, da } } } - BagMgrSingleton.AddItems(p, items, 0, common.GainWayDiamondLottery, "system", "钻石抽奖", 0, 0, false) + BagMgrSingleton.AddItemsV2(&ItemParam{ + P: p, + Change: items, + Cost: []*model.ItemInfo{ + { + ItemId: common.ItemIDDiamond, + ItemNum: diamondNum, + }, + }, + Add: 0, + GainWay: common.GainWayDiamondLottery, + Operator: "system", + Remark: "钻石抽奖", + gameId: 0, + gameFreeId: 0, + noLog: false, + }) pack.LuckyScore = p.DiamondLotteryScore p.SendToClient(int(player_proto.PlayerPacketID_PACKET_SC_DiamondLottery), pack) logger.Logger.Trace("返回钻石抽奖信息:", pack.String())