Merge branch 'feature/huangqijiuguan' into dev
This commit is contained in:
commit
92ff993129
@ -413,7 +413,7 @@ export default class HQJGFun {
|
||||
|
||||
mydata.giftbuy[gift.id].num++;
|
||||
// 发送奖励
|
||||
await PlayerFun.sendPrize(call, prize)
|
||||
await PlayerFun.sendPrize(call, prize, true);
|
||||
await this.setMyData(call.uid, hd.hdid, { giftbuy: mydata.giftbuy });
|
||||
}
|
||||
|
||||
|
@ -165,7 +165,7 @@ export class PlayerFun {
|
||||
/**
|
||||
* 发送奖励
|
||||
*/
|
||||
static async sendPrize(call: call, prizeList: atn[]) {
|
||||
static async sendPrize(call: call, prizeList: atn[], pushToClient=false) {
|
||||
prizeList = PublicShared.mergePrize(prizeList);
|
||||
|
||||
let attr = prizeList.filter(atn => atn.a == 'attr' && atn.n != 0);
|
||||
@ -188,6 +188,14 @@ export class PlayerFun {
|
||||
heroskin.length > 0 && this.addHeroskin(call, heroskin),
|
||||
]);
|
||||
|
||||
if(pushToClient){
|
||||
G.server.sendMsgByUid(call.uid, 'msg_s2c/Collection', {
|
||||
fromApi: `PlayerFun_sendPrize`,
|
||||
msg: call.eventMsg
|
||||
});
|
||||
call.eventMsg = {};
|
||||
}
|
||||
|
||||
return prizeList;
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user