59 lines
1.4 KiB
JavaScript
59 lines
1.4 KiB
JavaScript
"use strict";
|
|
cc._RF.push(module, '473adxD3P5Jq79BX64WCJhd', 'cmp.guild.talent.reset.tip');
|
|
// Scripts/mod/guild/talent/base/cmp.guild.talent.reset.tip.js
|
|
|
|
"use strict";
|
|
|
|
/******************************************************************
|
|
*
|
|
* 聯盟天賦 pvp重置天賦屬性
|
|
*
|
|
******************************************************************/
|
|
|
|
var BridgeWindow = require("bridge.window");
|
|
cc.Class({
|
|
"extends": BridgeWindow,
|
|
properties: {
|
|
nodTip: {
|
|
"default": null,
|
|
type: cc.Node
|
|
},
|
|
lstNeeds: {
|
|
"default": null,
|
|
type: cc.Node
|
|
}
|
|
},
|
|
onLoad: function onLoad() {},
|
|
// 重载:参数打开
|
|
onOpenConfigs: function onOpenConfigs(_params) {
|
|
this.first = _params.first;
|
|
this.tip = _params.tip;
|
|
this.res = _params.res;
|
|
this.cb = _params.cb;
|
|
/*****
|
|
* {"career":2,
|
|
* "lev":{"career":2,
|
|
* "attr_formation":[{"id":20001,"lev":7},
|
|
* {"id":20002,"lev":1},
|
|
* {"id":20003,"lev":5},
|
|
* {"id":20004,"lev":4}],
|
|
* "skill_id":0,"skill_lev":0}}
|
|
*/
|
|
this.fresh();
|
|
},
|
|
// 刷新
|
|
fresh: function fresh() {
|
|
nx.gui.setStringRich(this.nodTip, "", this.tip);
|
|
var cmp = this.lstNeeds.getComponent("cmp.item.layout");
|
|
if (cmp) {
|
|
cmp.rebuild(this.res);
|
|
}
|
|
},
|
|
// 点击确认
|
|
onTouchConfirm: function onTouchConfirm() {
|
|
nx.dt.fnInvoke(this.cb);
|
|
this.close();
|
|
}
|
|
});
|
|
|
|
cc._RF.pop(); |