This commit is contained in:
@@ -147,9 +147,12 @@ func (h Controller) BuyGoldItem(data *item.C2S_GOLD_BUY_PRODUCT, player *player.
|
||||
player.Info.Coins -= int64(usegold)
|
||||
|
||||
case 1:
|
||||
r := player.Service.Talk.Update(int(pro.ProductID), int(data.Count))
|
||||
if !r {
|
||||
return nil, errorcode.ErrorCodes.ErrGoldBeanSingleLimit
|
||||
}
|
||||
player.User.UpdateGold(player.Info.UserID, -int64(usegold))
|
||||
//购买成功,执行记录
|
||||
player.Service.Talk.Update(int(pro.ProductID), int(data.Count))
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user