|
@@ -6,6 +6,8 @@ import { BulletItem } from "../Script/game/cfg/bulletItem";
|
|
import { ConfigMgr } from "../Script/game/cfg/configMgr";
|
|
import { ConfigMgr } from "../Script/game/cfg/configMgr";
|
|
import { Utils } from "../Script/game/common/utils";
|
|
import { Utils } from "../Script/game/common/utils";
|
|
import { Barrage } from "../Script/game/nest/barrage";
|
|
import { Barrage } from "../Script/game/nest/barrage";
|
|
|
|
+import { NestPlay } from "../Script/game/nest/nestPlay";
|
|
|
|
+import { Draw } from "./test/draw";
|
|
|
|
|
|
const {ccclass, property} = cc._decorator;
|
|
const {ccclass, property} = cc._decorator;
|
|
|
|
|
|
@@ -13,14 +15,20 @@ const {ccclass, property} = cc._decorator;
|
|
export default class test extends cc.Component {
|
|
export default class test extends cc.Component {
|
|
|
|
|
|
/*===========================自动绑定组件开始===========================*/
|
|
/*===========================自动绑定组件开始===========================*/
|
|
|
|
+ /*自动生成*/
|
|
|
|
+ @property({type:cc.Node, displayName:""})
|
|
|
|
+ private $content_node:cc.Node = null;
|
|
|
|
+
|
|
/*自动生成*/
|
|
/*自动生成*/
|
|
@property({type:cc.Node, displayName:""})
|
|
@property({type:cc.Node, displayName:""})
|
|
private $layer_node:cc.Node = null;
|
|
private $layer_node:cc.Node = null;
|
|
-
|
|
|
|
- /*自动生成*/
|
|
|
|
|
|
+ /*自动生成*/
|
|
|
|
+ @property({type:cc.Node, displayName:""})
|
|
|
|
+ private $top_node:cc.Node = null;
|
|
|
|
+ /*自动生成*/
|
|
@property({type:cc.Node, displayName:""})
|
|
@property({type:cc.Node, displayName:""})
|
|
private $ui_node:cc.Node = null;
|
|
private $ui_node:cc.Node = null;
|
|
-
|
|
|
|
|
|
+
|
|
/*===========================自动绑定组件结束===========================*/
|
|
/*===========================自动绑定组件结束===========================*/
|
|
|
|
|
|
/*===========================自动生成按钮事件开始==========================*/
|
|
/*===========================自动生成按钮事件开始==========================*/
|
|
@@ -28,6 +36,19 @@ export default class test extends cc.Component {
|
|
/*===========================自动生成按钮事件结束==========================*/
|
|
/*===========================自动生成按钮事件结束==========================*/
|
|
|
|
|
|
protected async onLoad() {
|
|
protected async onLoad() {
|
|
|
|
+ await ConfigMgr.inst.init();
|
|
|
|
+ this.$content_node.addComponent(Draw);
|
|
|
|
+ let nestNode = Utils.createNode(this.$top_node, `nest`);
|
|
|
|
+ nestNode.addComponent(Draw);
|
|
|
|
+ let nestPlay = nestNode.addComponent(NestPlay);
|
|
|
|
+ nestPlay.init('101',1);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ async testCfg(){
|
|
|
|
+ await ConfigMgr.inst.init();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ async testBullet(){
|
|
await this.testCfg();
|
|
await this.testCfg();
|
|
UIMgr.inst.setup(this.$ui_node, UILayerNames.length, UILayerNames);
|
|
UIMgr.inst.setup(this.$ui_node, UILayerNames.length, UILayerNames);
|
|
UIMgr.inst.showUI(UIList.debug);
|
|
UIMgr.inst.showUI(UIList.debug);
|
|
@@ -40,8 +61,4 @@ export default class test extends cc.Component {
|
|
atk:80,
|
|
atk:80,
|
|
}, bulletItem);
|
|
}, bulletItem);
|
|
}
|
|
}
|
|
-
|
|
|
|
- async testCfg(){
|
|
|
|
- await ConfigMgr.inst.init();
|
|
|
|
- }
|
|
|
|
}
|
|
}
|