|
@@ -872,7 +872,7 @@
|
|
|
}
|
|
|
}
|
|
|
sendPost2025(reqUrl, data, call) {
|
|
|
- let isDev = true;
|
|
|
+ let isDev = false;
|
|
|
let urlTop = "https://api.kessongame.site/";
|
|
|
let urlMid = urlTop + "prod-api/api/game/";
|
|
|
if (isDev) {
|
|
@@ -5776,6 +5776,7 @@
|
|
|
constructor() {
|
|
|
super();
|
|
|
this.itemNums = 0;
|
|
|
+ this.curType = "";
|
|
|
}
|
|
|
onConstructor() {
|
|
|
this.ui = ui_UIShop.createInstance();
|
|
@@ -5783,19 +5784,53 @@
|
|
|
this.isEject = false;
|
|
|
this.moneyNode = new MoneyNode(this.ui.moneyNode);
|
|
|
this.addUIClick(this.ui.closeNode.closeBtn, this.closeSelf);
|
|
|
+ this.addUIClick(this.ui.myNode.n_qiuGan, () => this.switchBtn("qiugan"));
|
|
|
+ this.addUIClick(this.ui.myNode.n_daoju, () => this.switchBtn("daoju"));
|
|
|
this.addUIClick(this.ui, this.interuptSecretary);
|
|
|
this.ui.myNode.myList.itemRenderer = Laya.Handler.create(this, this.renderBallRod, null, false);
|
|
|
this.ballRodArr = [];
|
|
|
this.itemNums = Object.keys(cfgTable.ballrodData).length;
|
|
|
this.ui.myNode.myList.numItems = this.itemNums;
|
|
|
- if (Moyu.isKs)
|
|
|
- this.ui.closeNode.closeBtn.x += 100;
|
|
|
}
|
|
|
- show() {
|
|
|
+ show(type) {
|
|
|
super.show();
|
|
|
+ console.log('zh:show type = ' + type);
|
|
|
+ this.curType = type == 0 ? "qiugan" : "daoju";
|
|
|
+ this.switchBtn("qiugan");
|
|
|
this.playSecretaryIdle();
|
|
|
this.updateBallRod();
|
|
|
}
|
|
|
+ test123() {
|
|
|
+ console.log('zh:test123 ');
|
|
|
+ }
|
|
|
+ switchBtn(type) {
|
|
|
+ console.log('zh:1111切換 sel type=' + type);
|
|
|
+ if (type == "") {
|
|
|
+ type = this.curType;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ if (this.curType == type) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.curType = type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (type == "qiugan") {
|
|
|
+ console.log('zh:qg sel');
|
|
|
+ this.ui.myNode.n_qiuGan.c1.selectedIndex = 0;
|
|
|
+ this.ui.myNode.n_daoju.c1.selectedIndex = 1;
|
|
|
+ this.ui.myNode.myList.visible = true;
|
|
|
+ this.ui.myNode.djList.visible = false;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ console.log('zh:dj sel');
|
|
|
+ this.ui.myNode.n_qiuGan.c1.selectedIndex = 1;
|
|
|
+ this.ui.myNode.n_daoju.c1.selectedIndex = 0;
|
|
|
+ this.ui.myNode.myList.visible = false;
|
|
|
+ this.ui.myNode.djList.visible = true;
|
|
|
+ }
|
|
|
+ }
|
|
|
updateBallRod() {
|
|
|
for (let index = 0; index < this.ballRodArr.length; index++) {
|
|
|
this.ballRodArr[index].updateSelf();
|
|
@@ -7356,7 +7391,7 @@
|
|
|
Moyu.sendDataEvent("secretary");
|
|
|
}
|
|
|
openShopView() {
|
|
|
- xGame.uiMgr.Show(UIShop);
|
|
|
+ xGame.uiMgr.Show(UIShop, 0);
|
|
|
}
|
|
|
openSignView() {
|
|
|
xGame.uiMgr.Show(UISign);
|
|
@@ -13123,8 +13158,8 @@
|
|
|
this.n41 = (this.getChild("n41"));
|
|
|
this.myList = (this.getChild("myList"));
|
|
|
this.djList = (this.getChild("djList"));
|
|
|
- this.n45 = (this.getChild("n45"));
|
|
|
- this.n_item = (this.getChild("n_item"));
|
|
|
+ this.n_qiuGan = (this.getChild("n_qiuGan"));
|
|
|
+ this.n_daoju = (this.getChild("n_daoju"));
|
|
|
this.t0 = this.getTransition("t0");
|
|
|
}
|
|
|
}
|
|
@@ -14473,6 +14508,7 @@
|
|
|
return (fgui.UIPackage.createObject("game", "Component_daoju"));
|
|
|
}
|
|
|
onConstruct() {
|
|
|
+ this.n0 = (this.getChild("n0"));
|
|
|
}
|
|
|
}
|
|
|
ui_Component_daoju.URL = "ui://isxx5ak7nmu9v57t";
|
|
@@ -15109,6 +15145,17 @@
|
|
|
}
|
|
|
ui_Component119.URL = "ui://isxx5ak7u8eiv4i3";
|
|
|
|
|
|
+ class ui_Component_daoju_item extends fgui.GComponent {
|
|
|
+ static createInstance() {
|
|
|
+ return (fgui.UIPackage.createObject("game", "Component_daoju_item"));
|
|
|
+ }
|
|
|
+ onConstruct() {
|
|
|
+ this.n1 = (this.getChild("n1"));
|
|
|
+ this.n0 = (this.getChild("n0"));
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ui_Component_daoju_item.URL = "ui://isxx5ak7uel8v58m";
|
|
|
+
|
|
|
class ui_Component132_1 extends fgui.GComponent {
|
|
|
static createInstance() {
|
|
|
return (fgui.UIPackage.createObject("game", "Component132_1"));
|
|
@@ -16041,6 +16088,7 @@
|
|
|
fgui.UIObjectFactory.setExtension(ui_againBtn.URL, ui_againBtn);
|
|
|
fgui.UIObjectFactory.setExtension(ui_Component118.URL, ui_Component118);
|
|
|
fgui.UIObjectFactory.setExtension(ui_Component119.URL, ui_Component119);
|
|
|
+ fgui.UIObjectFactory.setExtension(ui_Component_daoju_item.URL, ui_Component_daoju_item);
|
|
|
fgui.UIObjectFactory.setExtension(ui_Component132_1.URL, ui_Component132_1);
|
|
|
fgui.UIObjectFactory.setExtension(ui_SecretaryDisplay.URL, ui_SecretaryDisplay);
|
|
|
fgui.UIObjectFactory.setExtension(ui_BallRodDisplay.URL, ui_BallRodDisplay);
|
|
@@ -22106,6 +22154,7 @@
|
|
|
constructor() {
|
|
|
super();
|
|
|
this.itemNums = 0;
|
|
|
+ this.curType = "";
|
|
|
}
|
|
|
onConstructor() {
|
|
|
this.ui = ui_UIShop.createInstance();
|
|
@@ -22113,19 +22162,53 @@
|
|
|
this.isEject = false;
|
|
|
this.moneyNode = new MoneyNode$1(this.ui.moneyNode);
|
|
|
this.addUIClick(this.ui.closeNode.closeBtn, this.closeSelf);
|
|
|
+ this.addUIClick(this.ui.myNode.n_qiuGan, () => this.switchBtn("qiugan"));
|
|
|
+ this.addUIClick(this.ui.myNode.n_daoju, () => this.switchBtn("daoju"));
|
|
|
this.addUIClick(this.ui, this.interuptSecretary);
|
|
|
this.ui.myNode.myList.itemRenderer = Laya.Handler.create(this, this.renderBallRod, null, false);
|
|
|
this.ballRodArr = [];
|
|
|
this.itemNums = Object.keys(cfgTable.ballrodData).length;
|
|
|
this.ui.myNode.myList.numItems = this.itemNums;
|
|
|
- if (Moyu.isKs)
|
|
|
- this.ui.closeNode.closeBtn.x += 100;
|
|
|
}
|
|
|
- show() {
|
|
|
+ show(type) {
|
|
|
super.show();
|
|
|
+ console.log('zh:show type = ' + type);
|
|
|
+ this.curType = type == 0 ? "qiugan" : "daoju";
|
|
|
+ this.switchBtn("qiugan");
|
|
|
this.playSecretaryIdle();
|
|
|
this.updateBallRod();
|
|
|
}
|
|
|
+ test123() {
|
|
|
+ console.log('zh:test123 ');
|
|
|
+ }
|
|
|
+ switchBtn(type) {
|
|
|
+ console.log('zh:1111切換 sel type=' + type);
|
|
|
+ if (type == "") {
|
|
|
+ type = this.curType;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ if (this.curType == type) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.curType = type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (type == "qiugan") {
|
|
|
+ console.log('zh:qg sel');
|
|
|
+ this.ui.myNode.n_qiuGan.c1.selectedIndex = 0;
|
|
|
+ this.ui.myNode.n_daoju.c1.selectedIndex = 1;
|
|
|
+ this.ui.myNode.myList.visible = true;
|
|
|
+ this.ui.myNode.djList.visible = false;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ console.log('zh:dj sel');
|
|
|
+ this.ui.myNode.n_qiuGan.c1.selectedIndex = 1;
|
|
|
+ this.ui.myNode.n_daoju.c1.selectedIndex = 0;
|
|
|
+ this.ui.myNode.myList.visible = false;
|
|
|
+ this.ui.myNode.djList.visible = true;
|
|
|
+ }
|
|
|
+ }
|
|
|
updateBallRod() {
|
|
|
for (let index = 0; index < this.ballRodArr.length; index++) {
|
|
|
this.ballRodArr[index].updateSelf();
|
|
@@ -23363,7 +23446,7 @@
|
|
|
Moyu.sendDataEvent("secretary");
|
|
|
}
|
|
|
openShopView() {
|
|
|
- xGame.uiMgr.Show(UIShop$1);
|
|
|
+ xGame.uiMgr.Show(UIShop$1, 0);
|
|
|
}
|
|
|
openSignView() {
|
|
|
xGame.uiMgr.Show(UISign$1);
|