diff --git a/worldsrv/action_bag.go b/worldsrv/action_bag.go index 66a00a0..b20697d 100644 --- a/worldsrv/action_bag.go +++ b/worldsrv/action_bag.go @@ -626,9 +626,11 @@ func CSDollChange(s *netlib.Session, packetid int, data interface{}, sid int64) }) logger.Logger.Trace("背包内使用兑换娃娃卡 bagInfo = ", bagInfo) pack.RetCode = rest + if isF { + itemId := item.ItemId task.New(nil, task.CallableWrapper(func(o *basic.Object) interface{} { - dollLog := model.NewDbBagChangeDoll(p.Platform, p.SnId, item.ItemId, 1, 0, "", msg.Addr, msg.UserName, msg.UserTel) + dollLog := model.NewDbBagChangeDoll(p.Platform, p.SnId, itemId, 1, 0, "", msg.Addr, msg.UserName, msg.UserTel) return model.InsertDbBagChangeDollLog(dollLog) }), task.CompleteNotifyWrapper(func(data interface{}, t task.Task) { if data != nil {