商城兑换娃娃

This commit is contained in:
by 2024-09-25 09:47:40 +08:00
parent ad8b3fe1ce
commit 532ff64d3b
3 changed files with 4 additions and 3 deletions

View File

@ -35,7 +35,7 @@ const (
OpResultCode_OPRC_JCoinNotEnough OpResultCode = 8 //金券不足
OpResultCode_OPRC_VipLevelNotEnough OpResultCode = 9 //Vip等级不足
OpResultCode_OPRC_NotSIMCode OpResultCode = 10 //兑换码不足
OpResultCode_OPRC_DCoinNotEnough OpResultCode = 11 //娃娃不足
OpResultCode_OPRC_DCoinNotEnough OpResultCode = 11 //娃娃积分不足
)
// Enum value maps for OpResultCode.

View File

@ -14,7 +14,7 @@ enum OpResultCode {
OPRC_JCoinNotEnough = 8;//
OPRC_VipLevelNotEnough = 9;//Vip等级不足
OPRC_NotSIMCode = 10;//
OPRC_DCoinNotEnough = 11;//
OPRC_DCoinNotEnough = 11;//
}
//
enum SPacketID {

View File

@ -795,6 +795,7 @@ func (this *ShopMgr) GetExchangeData(platform string, id int32) *ExchangeShopInf
JPrice: info.JPrice,
Cash: info.Cash,
Id: info.Id,
DPrice: info.DPrice,
})
}
var telData []*shop.TelChargeData
@ -926,7 +927,7 @@ func (this *ShopMgr) Exchange(p *Player, goodsId int32, username, mobile, commen
}
if info.DPrice > 0 {
n := int64(info.DPrice * num)
item := BagMgrSingleton.GetItem(p.SnId, common.ItemIDJCard)
item := BagMgrSingleton.GetItem(p.SnId, common.ItemDollCard)
if item != nil && item.ItemNum >= n {
BagMgrSingleton.AddItems(&model.AddItemParam{
Platform: p.Platform,