修改邀请tip的显示
This commit is contained in:
parent
d7246ec672
commit
5e5da2a214
@ -25,10 +25,13 @@
|
||||
"_components": [
|
||||
{
|
||||
"__id__": 5
|
||||
},
|
||||
{
|
||||
"__id__": 6
|
||||
}
|
||||
],
|
||||
"_prefab": {
|
||||
"__id__": 6
|
||||
"__id__": 7
|
||||
},
|
||||
"_opacity": 255,
|
||||
"_color": {
|
||||
@ -202,6 +205,19 @@
|
||||
"_atlas": null,
|
||||
"_id": ""
|
||||
},
|
||||
{
|
||||
"__type__": "754dd8JsnNGwoGLjRjfrLBY",
|
||||
"_name": "",
|
||||
"_objFlags": 0,
|
||||
"node": {
|
||||
"__id__": 1
|
||||
},
|
||||
"_enabled": true,
|
||||
"txtLabel": {
|
||||
"__id__": 3
|
||||
},
|
||||
"_id": ""
|
||||
},
|
||||
{
|
||||
"__type__": "cc.PrefabInfo",
|
||||
"root": {
|
||||
|
24
assets/scripts/inviteTip.js
Normal file
24
assets/scripts/inviteTip.js
Normal file
@ -0,0 +1,24 @@
|
||||
cc.Class({
|
||||
extends: cc.Component,
|
||||
|
||||
properties: {
|
||||
txtLabel: {
|
||||
default: null,
|
||||
type: cc.Label
|
||||
}
|
||||
},
|
||||
|
||||
// LIFE-CYCLE CALLBACKS:
|
||||
|
||||
onLoad () {
|
||||
|
||||
},
|
||||
|
||||
start () {
|
||||
},
|
||||
|
||||
// update (dt) {},
|
||||
setLabelTxt(str) {
|
||||
this.txtLabel.string = str;
|
||||
}
|
||||
});
|
9
assets/scripts/inviteTip.js.meta
Normal file
9
assets/scripts/inviteTip.js.meta
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"ver": "1.0.5",
|
||||
"uuid": "754ddf09-b273-46c2-818b-8d18dfacb058",
|
||||
"isPlugin": false,
|
||||
"loadPluginInWeb": true,
|
||||
"loadPluginInNative": true,
|
||||
"loadPluginInEditor": false,
|
||||
"subMetas": {}
|
||||
}
|
@ -75,6 +75,7 @@ cc.Class({
|
||||
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);
|
||||
|
Loading…
x
Reference in New Issue
Block a user