91 lines
2.1 KiB
JavaScript
91 lines
2.1 KiB
JavaScript
cc.Class({
|
|
extends: cc.Component,
|
|
|
|
properties: {
|
|
part1: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
part2: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
part3: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
part4: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
part5: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
processBarPrefab: {
|
|
default: null,
|
|
type: cc.Prefab
|
|
},
|
|
puzzlePrefab: {
|
|
default: null,
|
|
type: cc.Prefab
|
|
},
|
|
tipPrefab: {
|
|
default: null,
|
|
type: cc.Prefab
|
|
},
|
|
imageSwiperPrefab: {
|
|
default: null,
|
|
type: cc.Prefab
|
|
},
|
|
bottomSwiperPrefab: {
|
|
default: null,
|
|
type: cc.Prefab
|
|
},
|
|
joinBtn: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
inviteBtn: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
ruleBtn: {
|
|
default: null,
|
|
type: cc.Node
|
|
},
|
|
loginStatusLabel: {
|
|
default: null,
|
|
type: cc.Label
|
|
},
|
|
logoutBtn: {
|
|
default: null,
|
|
type: cc.Node
|
|
}
|
|
},
|
|
|
|
// LIFE-CYCLE CALLBACKS:
|
|
|
|
onLoad () {
|
|
this.loginStatusLabel.node.active = false;
|
|
var processBar = cc.instantiate(this.processBarPrefab);
|
|
processBar.getComponent('progressBar').currentVal = 1024;
|
|
this.part1.addChild(processBar);
|
|
var puzzle = cc.instantiate(this.puzzlePrefab);
|
|
this.part2.addChild(puzzle);
|
|
var tip = cc.instantiate(this.tipPrefab);
|
|
this.part2.addChild(tip);
|
|
tip.getComponent('inviteTip').setLabelTxt('xx接受了您的邀请');
|
|
var imageSwiper = cc.instantiate(this.imageSwiperPrefab);
|
|
this.part4.addChild(imageSwiper, 0);
|
|
var bottomSwiper = cc.instantiate(this.bottomSwiperPrefab);
|
|
this.part5.addChild(bottomSwiper);
|
|
},
|
|
|
|
start () {
|
|
},
|
|
|
|
// update (dt) {},
|
|
|
|
});
|