|
@@ -60,31 +60,22 @@ export default class LuojigouFinish extends cc.Component {
|
|
|
};
|
|
|
|
|
|
updateUI() {
|
|
|
+ // 动画
|
|
|
this.node.active = true;
|
|
|
this.nodeSuc.active = true;
|
|
|
this.nodeSuc.getChildByName('spine').active = true;
|
|
|
this.nodeSuc.getChildByName('spine').scale = this.dataQues.nodeSuc.spine.scale;
|
|
|
this.nodeSuc.getChildByName('score').active = false;
|
|
|
this.nodeSuc.getChildByName('score').opacity = this.dataQues.nodeSuc.score.opacity;
|
|
|
-
|
|
|
+ // 智慧币
|
|
|
this.nodeCoin.active = true;
|
|
|
this.nodeCoin.getChildByName('coin').active = false;
|
|
|
this.nodeCoin.getChildByName('coin').position = this.dataQues.nodeCoin.coin.position;
|
|
|
this.nodeCoin.getChildByName('sign').scale = this.dataQues.nodeCoin.sign.scale;
|
|
|
- let arrCoinCoin = Tools.getArrByNode(this.nodeCoin.getChildByName('coin'), 'icon');
|
|
|
- arrCoinCoin.forEach((item) => {
|
|
|
- item.scale = this.dataQues.nodeSuc.coin.scale;
|
|
|
- item.position = cc.v3(0, 0, 0);
|
|
|
- });
|
|
|
- }
|
|
|
-
|
|
|
- initGameFinish() {
|
|
|
- this.node.active = true;
|
|
|
- this.nodeSuc.active = false;
|
|
|
- this.nodeLimit.active = false;
|
|
|
- this.nodeCoin.active = true;
|
|
|
let itemScore = this.nodeCoin.getChildByName('score');
|
|
|
itemScore.getComponent(cc.Label).string = String(common.coinBase.data.userWisdomCoin);
|
|
|
+ // 已达上限
|
|
|
+ this.nodeLimit.active = false;
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -92,6 +83,7 @@ export default class LuojigouFinish extends cc.Component {
|
|
|
* @description 星星数
|
|
|
*/
|
|
|
setAnimation(props: PropsFinish): void {
|
|
|
+ this.updateUI();
|
|
|
let coinData = common.coinBase.data;
|
|
|
let coinCur = coinData.userWisdomCoin;
|
|
|
let coinElse = coinData.remainderWisdomCoin;
|
|
@@ -102,7 +94,6 @@ export default class LuojigouFinish extends cc.Component {
|
|
|
common.httpReportdata();// 数据上报
|
|
|
common.setGameToLocal();// 修改本地数据
|
|
|
|
|
|
- this.updateUI();
|
|
|
let sucSpine = this.nodeSuc.getChildByName('spine');
|
|
|
let sucCoin = this.nodeSuc.getChildByName('coin');
|
|
|
let coinCoin = this.nodeCoin.getChildByName('coin');
|
|
@@ -110,6 +101,8 @@ export default class LuojigouFinish extends cc.Component {
|
|
|
let arrCoinCoin = Tools.getArrByNode(coinCoin, 'icon');
|
|
|
arrCoinCoin.forEach((item, index)=>{
|
|
|
item.active = index < props.star;
|
|
|
+ item.scale = this.dataQues.nodeSuc.coin.scale;
|
|
|
+ item.position = cc.v3(0, 0, 0);
|
|
|
});
|
|
|
|
|
|
let timeScale = 1.2;
|