|
|
|
@ -239,15 +239,7 @@ export class BuildingWindow extends UIBase {
|
|
|
|
|
//进入应急处置
|
|
|
|
|
} |
|
|
|
|
else {//恢复查看状态
|
|
|
|
|
let showData = DataManager.institutionData.getMoudleShowData(type); |
|
|
|
|
if (showData != null) { |
|
|
|
|
let camera = SceneManager.Instance.defaultCamera; |
|
|
|
|
//showData.cameraData.setDataToCamera(camera);
|
|
|
|
|
let cameraData = showData.cameraData; |
|
|
|
|
BabylonTool.AnimMoveCameraTargetAB(camera, 60, cameraData.target, cameraData.radius, cameraData.alpha, cameraData.beta); |
|
|
|
|
this.showZP(showData.showZP); |
|
|
|
|
PlanComponent.instance.isOpenAwning = showData.showZP; |
|
|
|
|
} |
|
|
|
|
this.recoverMoudleShow(type); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
else { |
|
|
|
@ -259,6 +251,24 @@ export class BuildingWindow extends UIBase {
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 恢复展示模块状态(视角、罩棚) |
|
|
|
|
* @param type
|
|
|
|
|
*/ |
|
|
|
|
recoverMoudleShow(type: JYZInfoMoudleType) { |
|
|
|
|
let showData = DataManager.institutionData.getMoudleShowData(type); |
|
|
|
|
console.log("恢复模块状态", showData); |
|
|
|
|
if (showData != null) { |
|
|
|
|
let camera = SceneManager.Instance.defaultCamera; |
|
|
|
|
//showData.cameraData.setDataToCamera(camera);
|
|
|
|
|
let cameraData = showData.cameraData; |
|
|
|
|
BabylonTool.AnimMoveCameraTargetAB(camera, 60, cameraData.target, cameraData.radius, cameraData.alpha, cameraData.beta); |
|
|
|
|
this.showZP(showData.showZP); |
|
|
|
|
PlanComponent.instance.isOpenAwning = showData.showZP; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
@ -345,6 +355,7 @@ export class BuildingWindow extends UIBase {
|
|
|
|
|
this.showJYZModules(JYZInfoMoudleType.AQSS, false); |
|
|
|
|
this.showJYZModules(JYZInfoMoudleType.YQHSGX, false); |
|
|
|
|
this.showJYZModules(JYZInfoMoudleType.YQHSGX, false); |
|
|
|
|
this.recoverMoudleShow(null); |
|
|
|
|
|
|
|
|
|
//this.onChangeCurrentBuildingItem(item);
|
|
|
|
|
|
|
|
|
@ -503,7 +514,7 @@ export class BuildingWindow extends UIBase {
|
|
|
|
|
instance.addBuildings(BuildingType.Normal, 0, (uiItem, index) => { |
|
|
|
|
if (index == 0 && uiItem.buildingInfo.isEnable) { |
|
|
|
|
instance.onChangeCurrentBuildingItem(uiItem, false); |
|
|
|
|
uiItem.lookAt(false); |
|
|
|
|
//uiItem.lookAt(false);
|
|
|
|
|
// console.log("默认选中" + uiItem.buildingInfo.buildingData.normalData.key);
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
@ -936,10 +947,12 @@ export class BuildingWindow extends UIBase {
|
|
|
|
|
} |
|
|
|
|
if (jyzShowData == null) { |
|
|
|
|
jyzShowData = new JYZShowData(moudleType, camera, showZP); |
|
|
|
|
DataManager.institutionData.JYZShowDatas.push(jyzShowData); |
|
|
|
|
} |
|
|
|
|
jyzShowData.moudleType = moudleType; |
|
|
|
|
jyzShowData.cameraData.getDataFromCamera(camera); |
|
|
|
|
jyzShowData.showZP = showZP; |
|
|
|
|
console.log("保存展示数据", DataManager.institutionData.JYZShowDatas); |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|