猫猫回礼增加宠物币奖励
This commit is contained in:
parent
82636c7dd6
commit
2bf8a710a4
@ -981,7 +981,7 @@ func (p *PlayroomMod) ShopBuy(id, num int, weeklyDiscount bool) ([]*item.Item, [
|
||||
if addItemId == 0 {
|
||||
return nil, nil, fmt.Errorf("ShopBuy AddItemId is 0")
|
||||
}
|
||||
if costItem == nil || len(costItem) == 0 {
|
||||
if len(costItem) == 0 {
|
||||
return nil, nil, fmt.Errorf("ShopBuy CostItem is nil or length is 0")
|
||||
}
|
||||
newCostItem := costItem[0].Num * num
|
||||
|
||||
@ -5017,6 +5017,9 @@ func ReqCatReturnGiftReward(player *Player, req *msg.ReqCatReturnGiftReward) err
|
||||
if score >= int(v.Total) && reward < int(v.Id) {
|
||||
items = append(items, item.MsgToItem(v.Reward)...)
|
||||
maxRewardId = max(maxRewardId, int(v.Id))
|
||||
if v.StarReward > 0 {
|
||||
items = append(items, item.NewItem(GoUtil.FormatStarItemNum(int(v.StarReward), player.GetOrderFactor()), 1))
|
||||
}
|
||||
}
|
||||
}
|
||||
if len(items) == 0 {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user