Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
dy 2023-12-22 20:59:37 +08:00
commit aaf133d37f
6 changed files with 17 additions and 9 deletions

View File

@ -51,7 +51,7 @@ export async function playerCanReceive(call: ApiCall, callError : boolean = true
if (playerActivityInfo) {
if (playerActivityInfo[zeroTime]) {
return {
payNum, remaining, result: false, activityInfo, showOffList, price
payNum, remaining, result: false, activityInfo, showOffList, price, gotAmount: playerActivityInfo[zeroTime]
};
}
}
@ -63,7 +63,7 @@ export async function playerCanReceive(call: ApiCall, callError : boolean = true
export default async function (call: ApiCall<ReqCanReceive, ResCanReceive>) {
const canReceiveResult = await playerCanReceive(call);
if (canReceiveResult) {
const { payNum, remaining, result, showOffList, price } = canReceiveResult;
call.succ({ payNum, remaining, result, showOffList, price });
const { payNum, remaining, result, showOffList, price, gotAmount } = canReceiveResult;
call.succ({ payNum, remaining, result, showOffList, price, gotAmount });
}
}

View File

@ -55,7 +55,7 @@ export type eventType = {
zhoumolibao: ResOpenZhoumolibao & { refreshTime: number; }
pobinglibao: ResOpenPobinglibao;
payForDiamond: {
[time: number]: number[]
[time: number]: number
}
} & {
[k: `${number}jijin`]: ResOpenYuedujijin;

View File

@ -150,7 +150,7 @@ export class PushGiftFun {
return {payId: i, val: []}
}))
// 推送客户端消息
G.server.sendMsgByUid(uid, "msg_s2c/PushGiftChange", 1);
G.server.sendMsgByUid(uid, "msg_s2c/PushGiftChange", conf.id);
}
static async buy(uid: string, payId: string) {
@ -173,7 +173,7 @@ export class PushGiftFun {
uid: uid, id: gift.id.toString()
}, {$inc: {[`buy.${index}`]: 1}})
// 推送客户端消息
G.server.sendMsgByUid(uid, "msg_s2c/PushGiftChange", 1);
G.server.sendMsgByUid(uid, "msg_s2c/PushGiftChange", gift.id);
}
}
}

View File

@ -8,4 +8,5 @@ export type ResCanReceive = {
result: boolean;
price: number;
showOffList: any[];
gotAmount?: number;
};

View File

@ -1 +1 @@
export type MsgPushGiftChange = 1;
export type MsgPushGiftChange = number;

View File

@ -10364,6 +10364,14 @@ export const serviceProto: ServiceProto<ServiceType> = {
"type": "Any"
}
}
},
{
"id": 5,
"name": "gotAmount",
"type": {
"type": "Number"
},
"optional": true
}
]
},
@ -18358,8 +18366,7 @@ export const serviceProto: ServiceProto<ServiceType> = {
}
},
"msg_s2c/MsgPushGiftChange/MsgPushGiftChange": {
"type": "Literal",
"literal": 1
"type": "Number"
},
"msg_s2c/MsgSendGift/MsgSendGift": {
"type": "Interface",