diff --git a/assets/Game/scripts/SlotScene.ts b/assets/Game/scripts/SlotScene.ts index db72bbb..da8ff51 100644 --- a/assets/Game/scripts/SlotScene.ts +++ b/assets/Game/scripts/SlotScene.ts @@ -262,11 +262,22 @@ export class SlotScene extends Component { } GameDataManager.instance.frb = this.spinInfo.Frb; - let count = frb.Ongoing.Frn - 1; - if (count <= 0) { - count = 0; + if (frb) { + let count = 0; + + if (frb.Ongoing != null) { + count = frb.Ongoing.Frn - 1; + } + if (frb.Finished != null) { + count = frb.Finished.Frn; + + } + if (count <= 0) { + count = 0; + } + this.SysGift.handleSysInfoFreeCount(count); } - this.SysGift.handleSysInfoFreeCount(count); + // if (frb?.Ongoing?.Frn - 1 != GameDataManager.instance.frb?.Ongoing?.Frn) { // this.SysGift.handleSysInfoFreeCount(this.spinInfo.Frb.Ongoing.Frn); // } diff --git a/assets/Game/scripts/game/SysGift.ts b/assets/Game/scripts/game/SysGift.ts index 31bdf44..5c6e01e 100644 --- a/assets/Game/scripts/game/SysGift.ts +++ b/assets/Game/scripts/game/SysGift.ts @@ -104,8 +104,12 @@ export class SysGift extends Component { handleSysInfoFreeCount(countNum: number) { let frb = GameDataManager.instance.frb; if (!frb) return; + let count = this.info.getChildByName('count'); + if (frb.Finished == null) { - let count = this.info.getChildByName('count'); + count.getComponent(Label).string = (countNum).toLocaleString(); + this.show(count); + } else { count.getComponent(Label).string = (countNum).toLocaleString(); this.show(count); }