修改镜头、线缆展示初始默认不选择线缆也可放大、因环境数据问题导致的保存刷新错误

This commit is contained in:
高国正 2025-01-02 20:48:00 +08:00
parent e80f815470
commit f8beaf313b
10 changed files with 63 additions and 102 deletions

Binary file not shown.

View File

@ -1,70 +0,0 @@
fileFormatVersion: 2
guid: 3a9d3f7be36426143afceebeda50a49d
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
: Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux64: 0
Exclude OSXUniversal: 0
Exclude WebGL: 1
Exclude Win: 0
Exclude Win64: 0
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: AnyCPU
DefaultValueInitialized: true
OS: AnyOS
- first:
Standalone: Linux64
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: OSXUniversal
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win
second:
enabled: 1
settings:
CPU: x86
- first:
Standalone: Win64
second:
enabled: 1
settings:
CPU: x86_64
- first:
Windows Store Apps: WindowsStoreApps
second:
enabled: 0
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

View File

@ -26235,6 +26235,8 @@ MonoBehaviour:
m_EditorClassIdentifier:
targetCamera: {fileID: 0}
distanceMultiplier: 0.05
canvas: {fileID: 0}
initialScale: {x: 0, y: 0, z: 0}
button: {fileID: 0}
text: {fileID: 0}
--- !u!1 &510495731
@ -49868,6 +49870,8 @@ MonoBehaviour:
m_EditorClassIdentifier:
targetCamera: {fileID: 0}
distanceMultiplier: 0.05
canvas: {fileID: 0}
initialScale: {x: 0, y: 0, z: 0}
button: {fileID: 0}
text: {fileID: 0}
--- !u!1 &971395179
@ -50369,6 +50373,8 @@ MonoBehaviour:
m_EditorClassIdentifier:
targetCamera: {fileID: 0}
distanceMultiplier: 0.05
canvas: {fileID: 0}
initialScale: {x: 0, y: 0, z: 0}
button: {fileID: 0}
text: {fileID: 0}
--- !u!1 &979444513
@ -89331,7 +89337,7 @@ MonoBehaviour:
jqr_bctp:
bdsp:
arguments:
token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE3MTU1MDM3NzAsInVzZXJuYW1lIjoiYWRtaW4ifQ.7YN8jilCSYeYs3EZd9Gxnu52ZwHkbelE2SgISNs9CPA
token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE3MzU4OTY4NjIsInVzZXJuYW1lIjoiYWRtaW4ifQ.Npm7DV06GqCj2mR7NN5gEChomrCaPYW-C_ECLrOslG8
heatThresholdValueMax:
heatThresholdValueMin:
humidityThresholdValueMax:
@ -124472,7 +124478,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: -63.99994, y: 487}
m_AnchoredPosition: {x: -63.999878, y: 487}
m_SizeDelta: {x: -1303.1125, y: -1040}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1332666221677478668
@ -150942,7 +150948,7 @@ PrefabInstance:
- target: {fileID: 1907843774066353948, guid: f12e732b7b6c24e489ac02c8af4e7a78,
type: 3}
propertyPath: m_AnchoredPosition.y
value: 0.0009675648
value: -0.00005074135
objectReference: {fileID: 0}
- target: {fileID: 1907843774098386396, guid: f12e732b7b6c24e489ac02c8af4e7a78,
type: 3}

View File

@ -140,6 +140,9 @@ public class CameraRT : MonoBehaviour
{
DOTween.Kill(transform, false);
DOTween.Kill(cameraTransform, false);
//DOTween.KillAll(transform, false);
//DOTween.KillAll(cameraTransform, false);
}
/// <summary>

View File

@ -367,7 +367,7 @@ public class SearchName : MonoBehaviour
var s = PatternChoose.Inst.xianlan.gameObject.GetComponentsInChildren<LineInfor>(true);
Array.ForEach(s, (item) =>
{
if (item.cableGroupName == objs_str[co])
if (co > 0 && item.cableGroupName == objs_str[co])
{
isFind = true;
if (ExtendedFlycam.Room. != ExtendedFlycam.Inst.room)
@ -412,7 +412,7 @@ public class SearchName : MonoBehaviour
}
});
if (!isFind)
if (co > 0 && !isFind)
{
//弹出提示——该线缆组不包含线缆
SecondConfirmPanel.DeleteConform(null, "该线缆组不包含线缆");

View File

@ -1 +1 @@
http://127.0.0.1:8081/
http://47.117.170.47:80/

View File

@ -6,7 +6,7 @@
"heatThresholdValueMin": "5",
"humidityThresholdValueMax": "20",
"humidityThresholdValueMin": "80",
"token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE3MTcwMzE0MzcsInVzZXJuYW1lIjoiYWRtaW4ifQ.yEakEpa36I1cM4Tbir9TKFeM_DD7wX8-ublUQ72i6_M"
"token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE3MzU5MDcyNjIsInVzZXJuYW1lIjoiYWRtaW4ifQ.cXS9OLTjefc32SA4P4nRnoH9vrR7GRMm9scBaPaYKxg"
},
"serverTime": "1715417370490"
}

View File

@ -416,7 +416,7 @@ public class GameManager : MonoBehaviour
foreach (var item in Cabinets_go)
{
var D = item.GetComponent<DeviceQuery>().deviceList;
if (D.id == rackId)
if (!string.IsNullOrEmpty(rackId) && D.id == rackId)
{
//温度
if (ENVs[i].pointType == "1")
@ -738,7 +738,12 @@ public class GameManager : MonoBehaviour
var e = Cabinets_go[i].GetComponent<ENVQuery>();
Debug.Log("##04.4 Count:" + ENVs.Count);
//if (ENVs[j].pointDeviceId == n.id)
if (ENVs[j].rackId == n.id)
if (string.IsNullOrEmpty(ENVs[j].rackId))
{
j++;
break;
}
else if (ENVs[j].rackId == n.id)
{
if (ENVs[j].pointType == "1")
{
@ -769,8 +774,10 @@ public class GameManager : MonoBehaviour
break;
}
}
else {
else
{
j++;
break;
}
Debug.Log("##04.5 Count:" + ENVs.Count);
}
@ -928,7 +935,7 @@ public class GameManager : MonoBehaviour
}
else
{
#region new
for (int j = 0; j < TmsCards.Count; j++)
{

View File

@ -115,7 +115,7 @@ public class WebInteraction : MonoBehaviour
{
if (ct != null)
{
robotPos= JsonConvert.DeserializeObject<List<RobotPos>>(ct);
robotPos = JsonConvert.DeserializeObject<List<RobotPos>>(ct);
}
else
{
@ -563,7 +563,7 @@ public class WebInteraction : MonoBehaviour
#endregion
//yield return 1;
//callback("http://192.168.41.106:8081/");
//callback("http://172.16.1.134:80/");
}

View File

@ -6,6 +6,7 @@ using Unity.Burst.CompilerServices;
using UnityEngine;
using UnityEngine.EventSystems;
using static BaseConf;
using static CabinetInfor;
/// <summary>
/// 点击脚本
@ -203,7 +204,7 @@ public class ClickEvent : MonoBehaviour
if (/*GameManager.Inst.magnifyState && */Menu.M_数字机房_场景管理 != CabinetUIManager.Instance.current_menu && !DOTween.IsTweening(ExtendedFlycam.Inst.gameObject))
{
if (Physics.Raycast(ray, out hit, 100, 1 << 14 | 1 << 6 | 1 << 8 | 1 << 13 | 1 << 11))//»ú¹ñ-6 ÃÅ-14 Ðîµç³Ø-15
if (Menu.M_数字机房_线缆连接_展示 != CabinetUIManager.Instance.current_menu && Physics.Raycast(ray, out hit, 100, 1 << 14 | 1 << 6 | 1 << 8 | 1 << 13 | 1 << 11))//机柜-6 门-14 蓄电池-15
{
if (hit.collider.gameObject.layer != 11 &&
(!GameManager.Inst.magnifyState || (GameManager.Inst.magnifyState && GameManager.Inst.FindParent(hit.collider.gameObject, GameManager.Inst.IsDesiredParent) == GameManager.Inst.nowCabine)) &&
@ -1087,29 +1088,43 @@ public class ClickEvent : MonoBehaviour
if (PatternChoose.Inst.xianlan.gameObject.activeSelf)
{
List<LineInfor> lineInfors = PatternChoose.Inst.xianlan.gameObject.GetComponentsInChildren<LineInfor>().ToList();
List<GameObject> cabinets = new List<GameObject>();
if (lineInfors != null)
if (lineInfors != null && lineInfors.Any(e => e.gameObject.activeInHierarchy))
{
for (int i = 0; i < lineInfors.Count; i++)
List<GameObject> cabinets = new List<GameObject>();
if (lineInfors != null)
{
var c1 = GameManager.Inst.FindParent(lineInfors[i].lines[0].gameObject, GameManager.Inst.IsDesiredParent);
var c2 = GameManager.Inst.FindParent(lineInfors[i].lines[1].gameObject, GameManager.Inst.IsDesiredParent);
for (int i = 0; i < lineInfors.Count; i++)
{
var c1 = GameManager.Inst.FindParent(lineInfors[i].lines[0].gameObject, GameManager.Inst.IsDesiredParent);
var c2 = GameManager.Inst.FindParent(lineInfors[i].lines[1].gameObject, GameManager.Inst.IsDesiredParent);
if (c1)
cabinets.Add(c1);
if (c2)
cabinets.Add(c2);
if (c1)
cabinets.Add(c1);
if (c2)
cabinets.Add(c2);
}
// 独有
var uniqueIn = (GameManager.Inst.Cabinets_go).Except<GameObject>(cabinets);
if (uniqueIn != null)
{
foreach (GameObject item in uniqueIn)
item.gameObject.SetActive(false);
}
for (int i = 0; i < cabinets.Count; i++)
cabinets[i].GetComponent<TransparentGlow>().F2();
}
// ¶ÀÓÐ
var uniqueIn = (GameManager.Inst.Cabinets_go).Except<GameObject>(cabinets);
if (uniqueIn != null)
}
else
{
var v = GameManager.Inst.Cabinets_go;
for (int i = 0; i < v.Count; i++)
{
foreach (GameObject item in uniqueIn)
item.gameObject.SetActive(false);
v[i].GetComponent<TransparentGlow>().F1();
v[i].SetActive(false);
}
for (int i = 0; i < cabinets.Count; i++)
cabinets[i].GetComponent<TransparentGlow>().F2();
gameObject.GetComponent<TransparentGlow>().F2();
gameObject.SetActive(true);
}
}
}
@ -1345,7 +1360,7 @@ public class ClickEvent : MonoBehaviour
}
if (selected_cabient == null)
{
CameraMgr.Instance.StoreTarget();
//CameraMgr.Instance.StoreTarget();
selected_cabient = cabine.transform;
}
//ExtendedFlycam.Inst.init_mainCamera_rot();