|
|
@@ -45,13 +45,13 @@ export default class SpeedUpUI extends cc.Component {
|
|
|
const cash_bar = gData.redBagCash.cash_bar;
|
|
|
let cash_data = gData.redBagCash.getItemDataByIndex(cash_bar);
|
|
|
if (!cash_data) return;
|
|
|
- const newRedMoney = redMoney > cash_data.type_value ? cash_data.type_value : redMoney;
|
|
|
+ const newRedMoney = redMoney > cash_data.redMoney ? cash_data.redMoney : redMoney;
|
|
|
this.lbl_reward_value.string = cash_data.money / 100 + '元';
|
|
|
- this.lbl_progress.string = newRedMoney + '/' + cash_data.type_value;
|
|
|
- const fillRange = newRedMoney / cash_data.type_value >= 1 ? 1 : newRedMoney / cash_data.type_value;
|
|
|
+ this.lbl_progress.string = newRedMoney + '/' + cash_data.redMoney;
|
|
|
+ const fillRange = newRedMoney / cash_data.redMoney >= 1 ? 1 : newRedMoney / cash_data.redMoney;
|
|
|
// this.spr_cash_out.fillRange = fillRange;
|
|
|
cc.tween(this.spr_cash_out).to(fillRange, { fillRange: fillRange }).start();
|
|
|
- if (redMoney >= cash_data.type_value) {
|
|
|
+ if (redMoney >= cash_data.redMoney) {
|
|
|
this.node_cash.play();
|
|
|
} else {
|
|
|
this.node_cash.stop();
|