diff --git a/GQ_TongXin/Assets/Prefabs/Prefabs/温湿度图标/温湿度.prefab b/GQ_TongXin/Assets/Prefabs/Prefabs/温湿度图标/温湿度.prefab index 8ca89c4c8..835cb4ed7 100644 --- a/GQ_TongXin/Assets/Prefabs/Prefabs/温湿度图标/温湿度.prefab +++ b/GQ_TongXin/Assets/Prefabs/Prefabs/温湿度图标/温湿度.prefab @@ -58,7 +58,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} m_Name: m_EditorClassIdentifier: - m_Material: {fileID: 0} + m_Material: {fileID: 2100000, guid: 3a3b5242babc65a4c898f644975a9f50, type: 2} m_Color: {r: 0.54509807, g: 0.9254902, b: 0.7176471, a: 1} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} @@ -311,15 +311,19 @@ MonoBehaviour: shidu_selected: {fileID: 21300000, guid: cf0029eed200f6741a2d40138edbe8cf, type: 3} yangan_normal: {fileID: 21300000, guid: 0357a829ccc2daa4e9aee2af4d522ae9, type: 3} yangan_selected: {fileID: 21300000, guid: f007671b4f6062646a0382930e2cecfa, type: 3} + shuijin_normal: {fileID: 0} + shuijin_selected: {fileID: 0} expand_image: {fileID: 6206996800221561048} wendu_expand: {fileID: 21300000, guid: 5b1b5e55f3cd87f4886d3bb9c4f68651, type: 3} shidu_expand: {fileID: 21300000, guid: 103d978a53ab87c48b69a1bd50d86390, type: 3} yangan_expand: {fileID: 21300000, guid: 484e09e8d24e4d94391ed0b9f6b1880f, type: 3} + shuijin_expand: {fileID: 0} textMeshPro: {fileID: 6206996799658441959} text: {fileID: 3083355702494639820} hightC: {r: 0.99215686, g: 0.34117648, b: 0.34117648, a: 1} hightM: {r: 0, g: 0.56078434, b: 1, a: 1} temperatureAndHumidity: {fileID: 6206996799886426826} + isNormal: 1 --- !u!1 &6206996799886426827 GameObject: m_ObjectHideFlags: 0 @@ -383,6 +387,8 @@ MonoBehaviour: m_EditorClassIdentifier: targetCamera: {fileID: 0} distanceMultiplier: 0.05 + button: {fileID: 0} + text: {fileID: 0} --- !u!1 &6206996800221561051 GameObject: m_ObjectHideFlags: 0 @@ -481,15 +487,19 @@ MonoBehaviour: shidu_selected: {fileID: 21300000, guid: cf0029eed200f6741a2d40138edbe8cf, type: 3} yangan_normal: {fileID: 21300000, guid: 0357a829ccc2daa4e9aee2af4d522ae9, type: 3} yangan_selected: {fileID: 21300000, guid: f007671b4f6062646a0382930e2cecfa, type: 3} + shuijin_normal: {fileID: 0} + shuijin_selected: {fileID: 0} expand_image: {fileID: 6206996800221561048} wendu_expand: {fileID: 21300000, guid: 5b1b5e55f3cd87f4886d3bb9c4f68651, type: 3} shidu_expand: {fileID: 21300000, guid: 103d978a53ab87c48b69a1bd50d86390, type: 3} yangan_expand: {fileID: 21300000, guid: 484e09e8d24e4d94391ed0b9f6b1880f, type: 3} + shuijin_expand: {fileID: 0} textMeshPro: {fileID: 6206996799658441959} text: {fileID: 3083355702494639820} hightC: {r: 0.99215686, g: 0.34117648, b: 0.34117648, a: 1} hightM: {r: 0, g: 0, b: 0, a: 0} temperatureAndHumidity: {fileID: 6206996799886426826} + isNormal: 1 --- !u!1 &6206996800505932347 GameObject: m_ObjectHideFlags: 0 diff --git a/GQ_TongXin/Assets/Scenes/SampleSceneG.unity b/GQ_TongXin/Assets/Scenes/SampleSceneG.unity index a68b958cd..3364bf9a1 100644 --- a/GQ_TongXin/Assets/Scenes/SampleSceneG.unity +++ b/GQ_TongXin/Assets/Scenes/SampleSceneG.unity @@ -13089,6 +13089,17 @@ MonoBehaviour: ID: 0 instruct: {fileID: 1719409012} uPosManager: {fileID: 0} +--- !u!114 &133065317 stripped +MonoBehaviour: + m_CorrespondingSourceObject: {fileID: 2897378311783766594, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + m_PrefabInstance: {fileID: 5725925197986154677} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!1 &133229711 GameObject: m_ObjectHideFlags: 0 @@ -16708,6 +16719,11 @@ MonoBehaviour: ID: 0 instruct: {fileID: 49699091} uPosManager: {fileID: 0} +--- !u!1 &167648968 stripped +GameObject: + m_CorrespondingSourceObject: {fileID: 6489707996390798452, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + m_PrefabInstance: {fileID: 5725925197986154677} + m_PrefabAsset: {fileID: 0} --- !u!1 &167667343 GameObject: m_ObjectHideFlags: 0 @@ -47183,7 +47199,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 461794ce7efcde545b81d400c68b5361, type: 3} m_Name: m_EditorClassIdentifier: - current_menu: 15 + current_menu: 16 cabinet_ui_base_list: [] door_list: [] transparentGlows_list: [] @@ -77661,6 +77677,11 @@ MonoBehaviour: ID: 0 instruct: {fileID: 2143259182} uPosManager: {fileID: 0} +--- !u!224 &734862545 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + m_PrefabInstance: {fileID: 5725925197986154677} + m_PrefabAsset: {fileID: 0} --- !u!1 &734908981 stripped GameObject: m_CorrespondingSourceObject: {fileID: 4652948882987968456, guid: c8f09218a803c944e84c2336104ca2f9, type: 3} @@ -121061,6 +121082,17 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!114 &1137803460 stripped +MonoBehaviour: + m_CorrespondingSourceObject: {fileID: 4065166176282489122, guid: cdff6149826a44f4abc275995ec2d804, type: 3} + m_PrefabInstance: {fileID: 90559731} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!1 &1138073670 stripped GameObject: m_CorrespondingSourceObject: {fileID: 6850442828968900727, guid: c8f09218a803c944e84c2336104ca2f9, type: 3} @@ -124873,6 +124905,7 @@ GameObject: serializedVersion: 6 m_Component: - component: {fileID: 1168817490} + - component: {fileID: 1168817491} m_Layer: 0 m_Name: "\u7EBF\u7F06" m_TagString: Untagged @@ -124895,6 +124928,18 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 20 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &1168817491 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1168817489} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9a32c63f709470c47b3e3f91d22b2cbd, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!1 &1168945951 GameObject: m_ObjectHideFlags: 0 @@ -150760,6 +150805,55 @@ MonoBehaviour: ID: 0 instruct: {fileID: 407302752} uPosManager: {fileID: 0} +--- !u!1 &1437316435 stripped +GameObject: + m_CorrespondingSourceObject: {fileID: 4728632908461866428, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + m_PrefabInstance: {fileID: 5725925197986154677} + m_PrefabAsset: {fileID: 0} +--- !u!114 &1437316439 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1437316435} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1137803460} + m_OnClick: + m_PersistentCalls: + m_Calls: [] --- !u!1 &1437370488 stripped GameObject: m_CorrespondingSourceObject: {fileID: 8651753021795636432, guid: c8f09218a803c944e84c2336104ca2f9, type: 3} @@ -152400,6 +152494,83 @@ MonoBehaviour: ID: 0 instruct: {fileID: 1905278946} uPosManager: {fileID: 0} +--- !u!1 &1453142314 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1453142315} + - component: {fileID: 1453142317} + - component: {fileID: 1453142316} + m_Layer: 0 + m_Name: "\u5DE1\u68C0\u753B\u9762" + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &1453142315 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1453142314} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1526548964} + m_Father: {fileID: 4362348816139420719} + m_RootOrder: 15 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 662, y: -72} + m_SizeDelta: {x: 424, y: 306} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1453142316 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1453142314} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 2100000, guid: 3a3b5242babc65a4c898f644975a9f50, type: 2} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 3d3b847ce43a8824cb1a83da54ae9458, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1453142317 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1453142314} + m_CullTransparentMesh: 1 --- !u!1 &1453148703 GameObject: m_ObjectHideFlags: 0 @@ -160502,6 +160673,140 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!1 &1526548963 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1526548964} + - component: {fileID: 1526548967} + - component: {fileID: 1526548966} + - component: {fileID: 1526548965} + m_Layer: 0 + m_Name: Button (Legacy) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1526548964 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1526548963} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1557583099} + m_Father: {fileID: 1453142315} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: -9, y: -28} + m_SizeDelta: {x: 30, y: 30} + m_Pivot: {x: 1, y: 1} +--- !u!114 &1526548965 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1526548963} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1526548966} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1453142314} + m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine + m_MethodName: SetActive + m_Mode: 6 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1526548966 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1526548963} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.003921569} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1526548967 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1526548963} + m_CullTransparentMesh: 1 --- !u!1 &1527149726 GameObject: m_ObjectHideFlags: 0 @@ -163965,6 +164270,86 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!1 &1557583098 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1557583099} + - component: {fileID: 1557583101} + - component: {fileID: 1557583100} + m_Layer: 0 + m_Name: Text (Legacy) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &1557583099 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1557583098} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1526548964} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1557583100 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1557583098} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 14 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 10 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Button +--- !u!222 &1557583101 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1557583098} + m_CullTransparentMesh: 1 --- !u!1 &1557793143 stripped GameObject: m_CorrespondingSourceObject: {fileID: 6611413624281872263, guid: c8f09218a803c944e84c2336104ca2f9, type: 3} @@ -191656,10 +192041,10 @@ MonoBehaviour: xlz_sc: arguments: token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2OTQzOTY1ODYsInVzZXJuYW1lIjoiMTgzMTIzNDU2NzgifQ.WuHqy9XUGEROFUAKsQbzywLVH_sa6JuCcn5_oO1PRCo - heatThresholdValueMax: 10 - heatThresholdValueMin: 10 - humidityThresholdValueMax: 10 - humidityThresholdValueMin: 10 + heatThresholdValueMax: 38 + heatThresholdValueMin: 26 + humidityThresholdValueMax: 90 + humidityThresholdValueMin: 70 isLoading: 0 Cabinet_quYu: - {fileID: 0} @@ -251279,18 +251664,6 @@ MonoBehaviour: m_StringArgument: m_BoolArgument: 0 m_CallState: 2 - - m_Target: {fileID: 963194229} - m_TargetAssemblyTypeName: ExtendedFlycam, Assembly-CSharp - m_MethodName: JingTou - m_Mode: 3 - m_Arguments: - m_ObjectArgument: {fileID: 0} - m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine - m_IntArgument: 0 - m_FloatArgument: 0 - m_StringArgument: - m_BoolArgument: 0 - m_CallState: 2 m_IsOn: 1 --- !u!1 &1332666222495822969 GameObject: @@ -287890,12 +288263,14 @@ MonoBehaviour: yellow_alarm: {r: 0.90196085, g: 0.5568628, b: 0.023529414, a: 1} blue_alarm: {r: 0, g: 0.91372555, b: 0.9176471, a: 1} roomCut: {fileID: 1794289008} + quanJing: {fileID: 1332666222484096775} sb_xz_page: {fileID: 4362348815730404585} sb_bj_page: {fileID: 4362348816834021968} dk_xz_page: {fileID: 4362348817005860676} dk_bj_page: {fileID: 2126159577475600051} - xianlan: {fileID: 1168817489} + xianlan: {fileID: 1168817491} uiToCabinet: {fileID: 4362348816482923669} + xunJianImg: {fileID: 1453142316} --- !u!114 &4362348816139420716 MonoBehaviour: m_ObjectHideFlags: 0 @@ -287984,6 +288359,7 @@ RectTransform: - {fileID: 4362348816482923668} - {fileID: 245605307} - {fileID: 1345271533} + - {fileID: 1453142315} m_Father: {fileID: 4362348816935953888} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} @@ -318394,6 +318770,26 @@ PrefabInstance: m_Modification: m_TransformParent: {fileID: 4362348816139420719} m_Modifications: + - target: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_Pivot.y + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_AnchorMax.y + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_AnchorMin.y + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_SizeDelta.y + value: 437.8 + objectReference: {fileID: 0} + - target: {fileID: 1320083961994690168, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_AnchoredPosition.y + value: -106.70557 + objectReference: {fileID: 0} - target: {fileID: 1320083962038788126, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} propertyPath: m_AnchorMax.y value: 0 @@ -318494,6 +318890,26 @@ PrefabInstance: propertyPath: m_LocalEulerAnglesHint.z value: 0 objectReference: {fileID: 0} + - target: {fileID: 1320083962101217945, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: bg + value: + objectReference: {fileID: 133065317} + - target: {fileID: 1320083962101217945, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: biaoTou + value: + objectReference: {fileID: 167648968} + - target: {fileID: 1320083962101217945, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: serarchBtn + value: + objectReference: {fileID: 1437316439} + - target: {fileID: 1320083962101217945, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: initialHeight + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1320083962101217945, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: rectTransform + value: + objectReference: {fileID: 734862545} - target: {fileID: 1320083962101217951, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} propertyPath: m_Name value: "Panel\u641C\u7D22\u6846" @@ -318530,6 +318946,18 @@ PrefabInstance: propertyPath: m_SizeDelta.y value: 0 objectReference: {fileID: 0} + - target: {fileID: 2897378311783766594, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_Color.a + value: 0.003921569 + objectReference: {fileID: 0} + - target: {fileID: 2897378311783766594, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_RaycastTarget + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 4728632908461866428, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} + propertyPath: m_Name + value: "Button_\u641C\u7D22" + objectReference: {fileID: 0} m_RemovedComponents: - {fileID: 8357765580518675660, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} m_SourcePrefab: {fileID: 100100000, guid: 1e43385ddb3feca44b3c45d23ef4fae7, type: 3} diff --git a/GQ_TongXin/Assets/Scripts/Camera/CameraRT.cs b/GQ_TongXin/Assets/Scripts/Camera/CameraRT.cs index 6f642392e..42ccb4d60 100644 --- a/GQ_TongXin/Assets/Scripts/Camera/CameraRT.cs +++ b/GQ_TongXin/Assets/Scripts/Camera/CameraRT.cs @@ -160,20 +160,28 @@ public class CameraRT : MonoBehaviour pos = camera_init_position; rot = camera_init_eulerAngles; pos_target = target_init_position; + _x = camera_init_eulerAngles.y; + _y = camera_init_eulerAngles.x; } break; case ExtendedFlycam.Room.机房: { pos = new Vector3(9.53f, 15.23f, -5.71f); rot = new Vector3(67.072f, 180, 0); - pos_target = new Vector3(9.67f, -3.9f, -13.5f); + pos_target = new Vector3(9.67f, 1.878f, -11.1f); + _x = 180f; + _y = 67.072f; + distance = 15; } break; case ExtendedFlycam.Room.配电室: { - pos = new Vector3(-4.09f, 14.52f, -6.4085f); + pos = new Vector3(-4.218f, 15.8f, -5.9f); rot = new Vector3(67.072f, 180, 0); - pos_target = new Vector3(-4.09f, -3.9f, -14.2f); + pos_target = new Vector3(-4.218f, 1.51f, -10.81f); + _x = 180f; + _y = 67.072f; + distance = 15; } break; default: @@ -182,24 +190,34 @@ public class CameraRT : MonoBehaviour } else { - switch (ExtendedFlycam.Inst.room) + //switch (ExtendedFlycam.Inst.room) + //{ + // case ExtendedFlycam.Room.None: + // break; + // case ExtendedFlycam.Room.机房: + // { + // pos = new Vector3(2.55f, 20.82f, -7.50f); + // rot = new Vector3(90, 180, 0); + // pos_target = new Vector3(2.2f, -3.9f, -7f); + // _x = 180; + // _y = 90; + // maxDistance = distance = 25; + // } + // break; + // case ExtendedFlycam.Room.配电室: + // break; + // default: + // break; + //} + { - case ExtendedFlycam.Room.None: - break; - case ExtendedFlycam.Room.机房: - { - pos = new Vector3(2.55f, 20.82f, -7.50f); - rot = new Vector3(90, 180, 0); - pos_target = new Vector3(2.2f, -3.9f, -7f); - _x = 180; - _y = 90; - maxDistance = distance = 25; - } - break; - case ExtendedFlycam.Room.配电室: - break; - default: - break; + pos = new Vector3(-3.615f, 26.878f, -5.0f); + rot = new Vector3(90, 180, 0); + //pos_target = new Vector3(9.67f, 1.878f, -11.1f); + pos_target = new Vector3(-3.71f, 1.878f, -4.6f); + _x = 180; + _y = 90; + maxDistance = distance = 25; } } diff --git a/GQ_TongXin/Assets/Scripts/SearchName.cs b/GQ_TongXin/Assets/Scripts/SearchName.cs index 78d81f294..0a00a5785 100644 --- a/GQ_TongXin/Assets/Scripts/SearchName.cs +++ b/GQ_TongXin/Assets/Scripts/SearchName.cs @@ -3,6 +3,7 @@ using System; using System.Collections.Generic; using TMPro; using UnityEngine; +using UnityEngine.EventSystems; using UnityEngine.UI; @@ -15,6 +16,10 @@ public class SearchName : MonoBehaviour public Transform scrollViewContent; public TMP_InputField inputField; public GameObject prefabsText; + /// + /// ť + /// + public Button serarchBtn; [Header("Ҫ豸")] public List objs = new List(); public List objs_str = new List(); @@ -30,15 +35,34 @@ public class SearchName : MonoBehaviour /// public Dictionary dic_notContain = new Dictionary(); + public float initialHeight; + public RectTransform rectTransform; + public GameObject biaoTou; + public Image bg; + private void Awake() { + rectTransform = scrollView.GetComponent(); + initialHeight = rectTransform.sizeDelta.y; + rectTransform.sizeDelta = new Vector2(rectTransform.sizeDelta.x, 0); gameObject.SetActive(false); + biaoTou.SetActive(false); } void Start() { //searchType = SearchType.None; //scrollView.SetActive(false); InputFieldEvent(); + + OnClickSearchBtn(); + } + + private void OnClickSearchBtn() + { + serarchBtn.onClick.AddListener(() => + { + show_menu(); + }); } void InputFieldEvent() @@ -222,7 +246,7 @@ public class SearchName : MonoBehaviour List transparentGlows = new List(); - var s = PatternChoose.Inst.xianlan.GetComponentsInChildren(true); + var s = PatternChoose.Inst.xianlan.gameObject.GetComponentsInChildren(true); Array.ForEach(s, (item) => { if (item.name == objs_str[co]) @@ -234,7 +258,7 @@ public class SearchName : MonoBehaviour transparentGlows.Add(go2.GetComponent()); item.gameObject.SetActive(true); } - else if (dic_notContain.ContainsKey(objs_str[co])) + else if (dic_notContain.ContainsKey(objs_str[co])) { //ʾ鲻 SecondConfirmPanel.DeleteConform(null, "鲻"); @@ -387,7 +411,49 @@ public class SearchName : MonoBehaviour private void Update() { + if (!EventSystem.current.IsPointerOverGameObject() && !inputField.isFocused && biaoTou.activeSelf) + { + hide_menu(); + } + bg.raycastTarget = scrollView.activeSelf; + } + /// + /// ˵ + /// + public void hide_menu() + { + { + DOTween.Kill(rectTransform, false); + + biaoTou.SetActive(false); + + float targetHeight = 0; + float duration = 1f; + + rectTransform.DOSizeDelta(new Vector2(rectTransform.sizeDelta.x, targetHeight), duration).OnComplete(() => + { + scrollView.SetActive(false); + }); + } + } + + /// + /// ʾ˵ + /// + public void show_menu() + { + { + DOTween.Kill(rectTransform, false); + + scrollView.SetActive(true); + biaoTou.SetActive(true); + + float targetHeight = initialHeight; + float duration = 1f; + + rectTransform.DOSizeDelta(new Vector2(rectTransform.sizeDelta.x, targetHeight), duration); + } } /// diff --git a/GQ_TongXin/Assets/Scripts/WJ/DigitalTwinPanel.cs b/GQ_TongXin/Assets/Scripts/WJ/DigitalTwinPanel.cs index f6ff371cb..cb1a116f3 100644 --- a/GQ_TongXin/Assets/Scripts/WJ/DigitalTwinPanel.cs +++ b/GQ_TongXin/Assets/Scripts/WJ/DigitalTwinPanel.cs @@ -18,9 +18,11 @@ public class DigitalTwinPanel : CabinetUIBase public bool hold; public static DigitalTwinPanel selected_panel; + public Image img; // Start is called before the first frame update void Start() { + img = PatternChoose.Inst.xunJianImg; Camera = UnityEngine.Camera.main.transform; textMesh.text = transform.parent.name; hold_button.onClick.AddListener(() => @@ -47,6 +49,7 @@ public class DigitalTwinPanel : CabinetUIBase { RobotManager.Instance.DoAnimation(); RobotManager.Instance.ShowVideo(); + img.gameObject.SetActive(true); } }); } diff --git a/GQ_TongXin/Assets/Scripts/WJ/LineGroup/LineGroupManager.cs b/GQ_TongXin/Assets/Scripts/WJ/LineGroup/LineGroupManager.cs index 2be2c11a1..cdde86a05 100644 --- a/GQ_TongXin/Assets/Scripts/WJ/LineGroup/LineGroupManager.cs +++ b/GQ_TongXin/Assets/Scripts/WJ/LineGroup/LineGroupManager.cs @@ -38,7 +38,7 @@ public class LineGroupManager : MonoBehaviour public void addxianlan() { - GameObject xianlan = PatternChoose.Inst.xianlan; + GameObject xianlan = PatternChoose.Inst.xianlan.gameObject; GameManager.Inst.FindPortPos(); for (int i = 0; i < child_line_group_items.Count; i++) diff --git a/GQ_TongXin/Assets/Scripts/WJ/SpUI.cs b/GQ_TongXin/Assets/Scripts/WJ/SpUI.cs index 036beb516..efaf16996 100644 --- a/GQ_TongXin/Assets/Scripts/WJ/SpUI.cs +++ b/GQ_TongXin/Assets/Scripts/WJ/SpUI.cs @@ -106,19 +106,19 @@ public class SpUI : MonoBehaviour, IPointerEnterHandler, IPointerExitHandler { my_image.color = hightC; isNormal = false; - expand_image.gameObject.SetActive(true); + EnterUI(); } else if (float.Parse(a) < float.Parse(min)) { my_image.color = hightM; isNormal = false; - expand_image.gameObject.SetActive(true); + EnterUI(); } else { my_image.color = new Color(1, 1, 1, 1); isNormal = true; - expand_image.gameObject.SetActive(false); + ExitUI(); } } @@ -128,13 +128,13 @@ public class SpUI : MonoBehaviour, IPointerEnterHandler, IPointerExitHandler { my_image.color = new Color(1, 1, 1, 1); isNormal = true; - expand_image.gameObject.SetActive(false); + ExitUI(); } else { my_image.color = hightC; isNormal = false; - expand_image.gameObject.SetActive(true); + EnterUI(); } } } diff --git a/GQ_TongXin/Assets/Scripts/WJ/UIToCabinet.cs b/GQ_TongXin/Assets/Scripts/WJ/UIToCabinet.cs index 9da53e3b9..058e2bb64 100644 --- a/GQ_TongXin/Assets/Scripts/WJ/UIToCabinet.cs +++ b/GQ_TongXin/Assets/Scripts/WJ/UIToCabinet.cs @@ -66,7 +66,7 @@ public class UIToCabinet : MonoBehaviour var index = i; toggles[index].onValueChanged.AddListener((ison) => { - if (!toggles[index].gameObject.activeInHierarchy) + if (!toggles[index].gameObject.activeInHierarchy) return; if (ison) { @@ -225,7 +225,7 @@ public class UIToCabinet : MonoBehaviour { init(Menu.M__Ѳ); //ExtendedFlycam.Inst.QuanJing(); - + GameManager.Inst.search_box.SetActive(false); ExtendedFlycam.Inst.QieHuan(Menu.M__Ѳ); CabinetUIManager.ChangeMenu(Menu.M__Ѳ); @@ -323,6 +323,7 @@ public class UIToCabinet : MonoBehaviour /// public void UI_init() { + PatternChoose.Inst.xunJianImg.gameObject.SetActive(false); WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber); GameManager.Inst.power_close(); diff --git a/GQ_TongXin/Assets/script/GameManager.cs b/GQ_TongXin/Assets/script/GameManager.cs index d45e3b37e..2b8fa6894 100644 --- a/GQ_TongXin/Assets/script/GameManager.cs +++ b/GQ_TongXin/Assets/script/GameManager.cs @@ -1872,8 +1872,12 @@ public class GameManager : MonoBehaviour if (z != null) { Debug.Log("@@5"); - LoadScene(); - callback?.Invoke("1"); + StartCoroutine(PatternChoose.Inst.xianlan.getByCode((x)=> + { + Debug.Log("@@5.1"); + LoadScene(); + callback?.Invoke("1"); + })); } })); } @@ -2019,6 +2023,11 @@ public class GameManager : MonoBehaviour /// [Header("线缆组-查询URL")] public string xlz_sc; + /// + /// 线路类型-查询URL + /// + [Header("线路类型-查询URL")] public string xllx_sc; + public webURL(string ct) { //string ct = "http://fpt9gx.natappfree.cc/"; @@ -2040,6 +2049,8 @@ public class GameManager : MonoBehaviour xlz_cx = ct + "machineRoom/deviceLine/queryList"; xlz_xz = ct + "machineRoom/deviceLine/save"; xlz_sc = ct + "machineRoom/deviceLine/delete"; + + xllx_sc = ct + "machineRoom/sysParam/getByCode?code=line"; } } @@ -2057,19 +2068,19 @@ public class GameManager : MonoBehaviour /// /// 温度最大阈值 /// - public string heatThresholdValueMax; + [Tooltip("温度最大阈值")] public string heatThresholdValueMax; /// /// 温度最小阈值 /// - public string heatThresholdValueMin; + [Tooltip("温度最小阈值")] public string heatThresholdValueMin; /// /// 湿度最大阈值 /// - public string humidityThresholdValueMax; + [Tooltip("湿度最大阈值")] public string humidityThresholdValueMax; /// /// 湿度最小阈值 /// - public string humidityThresholdValueMin; + [Tooltip("湿度最小阈值")] public string humidityThresholdValueMin; } diff --git a/GQ_TongXin/Assets/script/JSON/CombineJSON.cs b/GQ_TongXin/Assets/script/JSON/CombineJSON.cs index ad3b11d16..7c37ea615 100644 --- a/GQ_TongXin/Assets/script/JSON/CombineJSON.cs +++ b/GQ_TongXin/Assets/script/JSON/CombineJSON.cs @@ -235,6 +235,7 @@ public static class CombineJSON else { Debug.Log("request.downloadHandler为null"); + callback.Invoke(null); } } else diff --git a/GQ_TongXin/Assets/script/SearchName1.cs b/GQ_TongXin/Assets/script/SearchName1.cs index 6bf2d2490..58058f378 100644 --- a/GQ_TongXin/Assets/script/SearchName1.cs +++ b/GQ_TongXin/Assets/script/SearchName1.cs @@ -4,6 +4,7 @@ using UnityEngine; using TMPro; using UnityEngine.UI; using DG.Tweening; +using UnityEngine.EventSystems; public class SearchName1 : MonoBehaviour { @@ -35,7 +36,7 @@ public class SearchName1 : MonoBehaviour private void Awake() { rectTransform = scrollView.GetComponent(); - //initialHeight = rectTransform.sizeDelta.y; + initialHeight = rectTransform.sizeDelta.y; rectTransform.sizeDelta = new Vector2(rectTransform.sizeDelta.x, 0); gameObject.SetActive(false); } @@ -116,6 +117,11 @@ public class SearchName1 : MonoBehaviour }); } + private void Update() + { + + } + /// /// ˵ /// diff --git a/GQ_TongXin/Assets/script/UI/PatternChoose.cs b/GQ_TongXin/Assets/script/UI/PatternChoose.cs index 9e98cec40..15bcbead5 100644 --- a/GQ_TongXin/Assets/script/UI/PatternChoose.cs +++ b/GQ_TongXin/Assets/script/UI/PatternChoose.cs @@ -29,6 +29,8 @@ public class PatternChoose : MonoBehaviour [SerializeField] public Color blue_alarm; public Toggle roomCut; + public Toggle quanJing; + /// /// 设备新增窗口 @@ -49,10 +51,12 @@ public class PatternChoose : MonoBehaviour /// /// 线缆 /// - public GameObject xianlan; + public ByCode xianlan; public UIToCabinet uiToCabinet; + public Image xunJianImg; + private void Awake() { if (_inst != null && _inst != this) @@ -71,8 +75,14 @@ public class PatternChoose : MonoBehaviour { roomCut.onValueChanged.AddListener((x) => { - if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_智能巡检) return; - ExtendedFlycam.Inst.QieHuan(CabinetUIManager.Instance.current_menu, false); + if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_智能巡检) + return; + ExtendedFlycam.Inst.QieHuan(CabinetUIManager.Instance.current_menu, 2); + }); + + quanJing.onValueChanged.AddListener((x) => + { + ExtendedFlycam.Inst.QieHuan(CabinetUIManager.Instance.current_menu); }); } diff --git a/GQ_TongXin/Assets/script/前端交互/WebInteraction.cs b/GQ_TongXin/Assets/script/前端交互/WebInteraction.cs index e289ed67b..202f0a799 100644 --- a/GQ_TongXin/Assets/script/前端交互/WebInteraction.cs +++ b/GQ_TongXin/Assets/script/前端交互/WebInteraction.cs @@ -145,28 +145,41 @@ public class WebInteraction : MonoBehaviour } - // ǰлͷ - public void unity_videoNumber(string videoNumber) + /// + /// ǰлͷ + /// + /// + public void unity_video_state(string videoNumber) { - var _videoNumbers = videoNumber.Split(','); - for (int i = 0; i < PatternChoose.Inst.uiToCabinet.clickEventLens.Count; i++) + if (!string.IsNullOrEmpty(videoNumber)) { - for (int j = 0; j < _videoNumbers.Length; j++) + var _videoNumbers = videoNumber.Split(','); + for (int i = 0; i < PatternChoose.Inst.uiToCabinet.clickEventLens.Count; i++) { - if (_videoNumbers[j] == PatternChoose.Inst.uiToCabinet.clickEventLens[i].text.text.Replace("", "")) + for (int j = 0; j < _videoNumbers.Length; j++) { - PatternChoose.Inst.uiToCabinet.clickEventLens[i].isplay = true; - PatternChoose.Inst.uiToCabinet.clickEventLens[i].ChangeMaterialColor(PatternChoose.Inst.uiToCabinet.clickEventLens[i].gameObject, 4); - break; - } - else - { - PatternChoose.Inst.uiToCabinet.clickEventLens[i].isplay = false; - PatternChoose.Inst.uiToCabinet.clickEventLens[i].ChangeMaterialColor(PatternChoose.Inst.uiToCabinet.clickEventLens[i].gameObject, 99); - break; + if (_videoNumbers[j] == PatternChoose.Inst.uiToCabinet.clickEventLens[i].text.text.Replace("", "")) + { + PatternChoose.Inst.uiToCabinet.clickEventLens[i].isplay = true; + PatternChoose.Inst.uiToCabinet.clickEventLens[i].ChangeMaterialColor(PatternChoose.Inst.uiToCabinet.clickEventLens[i].gameObject, 4); + break; + } + else + { + PatternChoose.Inst.uiToCabinet.clickEventLens[i].isplay = false; + PatternChoose.Inst.uiToCabinet.clickEventLens[i].ChangeMaterialColor(PatternChoose.Inst.uiToCabinet.clickEventLens[i].gameObject, 99); + } } } } + else + { + for (int i = 0; i < PatternChoose.Inst.uiToCabinet.clickEventLens.Count; i++) + { + PatternChoose.Inst.uiToCabinet.clickEventLens[i].isplay = false; + PatternChoose.Inst.uiToCabinet.clickEventLens[i].ChangeMaterialColor(PatternChoose.Inst.uiToCabinet.clickEventLens[i].gameObject, 99); + } + } } public Button bt; diff --git a/GQ_TongXin/Assets/script/接口/查询/ByCode.cs b/GQ_TongXin/Assets/script/接口/查询/ByCode.cs new file mode 100644 index 000000000..ce697b27e --- /dev/null +++ b/GQ_TongXin/Assets/script/接口/查询/ByCode.cs @@ -0,0 +1,107 @@ +using Newtonsoft.Json; +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class ByCode : MonoBehaviour +{ + public Root myroot = new Root(); + public Dictionary lineCode_dic = new Dictionary(); + + void Start() + { + + } + + // Update is called once per frame + void Update() + { + + } + + public IEnumerator getByCode(Action callback) + { + yield return StartCoroutine( + CombineJSON.GetJson_GET(GameManager.Inst.Jk_URL.xllx_sc, (jsonResult) => + { + try + { + myroot = JsonConvert.DeserializeObject(jsonResult); + if (myroot.data != null && myroot.message == "ɹ") + { + lineCode_dic.Clear(); + for (int i = 0; i < myroot.data.Count; i++) + { + //if (!lineCode_dic.ContainsKey(myroot.data[i].name)) + lineCode_dic.Add(myroot.data[i].name, myroot.data[i].value); + } + callback.Invoke("1"); + } + else + callback.Invoke(null); + } + catch (Exception e) + { + Debug.Log("ѯ·ͽӿڴ" + e.Message + e.StackTrace); + callback.Invoke(null); + } + }) + ); + } + + [System.Serializable] + public class Data + { + /// + /// + /// + public string id; + /// + /// + /// + public string code; + /// + /// Ƶ + /// + public string name; + /// + /// + /// + public string value; + /// + /// + /// + public int deleteFlag; + /// + /// + /// + public string remark; + /// + /// + /// + public int createTime; + } + + [System.Serializable] + public class Root + { + /// + /// + /// + public string code; + /// + /// ɹ + /// + public string message; + /// + /// + /// + public List data; + /// + /// + /// + public string serverTime; + } + +} diff --git a/GQ_TongXin/Assets/script/接口/查询/LineQuery.cs b/GQ_TongXin/Assets/script/接口/查询/LineQuery.cs index f32de4fbc..f971c1322 100644 --- a/GQ_TongXin/Assets/script/接口/查询/LineQuery.cs +++ b/GQ_TongXin/Assets/script/接口/查询/LineQuery.cs @@ -234,7 +234,7 @@ public class LineQuery : MonoBehaviour // ɾ public IEnumerable deleteCableName(string cableGroupName, string CableName, Action callback = null) { - var xianlan = PatternChoose.Inst.xianlan.GetComponentsInChildren(); + var xianlan = PatternChoose.Inst.xianlan.gameObject.GetComponentsInChildren(); var info = Array.Find(xianlan, (item) => { return (item.cableGroupName == cableGroupName && item.cableName == CableName); diff --git a/GQ_TongXin/Assets/script/点击/ClickEvent.cs b/GQ_TongXin/Assets/script/点击/ClickEvent.cs index d980f16f5..12a988a1f 100644 --- a/GQ_TongXin/Assets/script/点击/ClickEvent.cs +++ b/GQ_TongXin/Assets/script/点击/ClickEvent.cs @@ -725,7 +725,7 @@ public class ClickEvent : MonoBehaviour /// public void Zoomin(GameObject cabine) { - ExtendedFlycam.Inst.QieHuan(CabinetUIManager.Instance.current_menu, false); + ExtendedFlycam.Inst.QieHuan(CabinetUIManager.Instance.current_menu); GameManager.Inst.magnifyState = true; TransparentGlowManage.Inst.is_magnify = true; @@ -751,6 +751,13 @@ public class ClickEvent : MonoBehaviour } } + if(Menu.M___ != CabinetUIManager.Instance.current_menu) + { + Array.ForEach(cabine.GetComponentsInChildren(), (itme) => + { + itme.hight.SetActive(false); + }); + } if (cabine.transform.Find("Uλ")) GameManager.Inst.gameObject.GetComponent().dragController.uPosManger = cabine.transform.Find("Uλ").GetComponent(); diff --git a/GQ_TongXin/Assets/script/画线/CreateLine.cs b/GQ_TongXin/Assets/script/画线/CreateLine.cs index 6875f20fd..f35d2e9d3 100644 --- a/GQ_TongXin/Assets/script/画线/CreateLine.cs +++ b/GQ_TongXin/Assets/script/画线/CreateLine.cs @@ -143,7 +143,7 @@ public class CreateLine : CabinetUIBase Vector3 v5 = B.position; vector3s.Add(v1); - if(vector3s[vector3s.Count-1]!=v2) vector3s.Add(v2); + if (vector3s[vector3s.Count - 1] != v2) vector3s.Add(v2); if (vector3s[vector3s.Count - 1] != v3) vector3s.Add(v3); if (vector3s[vector3s.Count - 1] != v4) vector3s.Add(v4); if (vector3s[vector3s.Count - 1] != v5) vector3s.Add(v5); @@ -161,6 +161,36 @@ public class CreateLine : CabinetUIBase l.lines.Add(B); l.cableGroupName = p.cableGroupName; l.cableName = p.cableName; + l.portType = p.portType; + + try + { + HexToColor(PatternChoose.Inst.xianlan.lineCode_dic[p.portType], (x) => + { + lineRenderer.startColor = x; + }); + HexToColor(PatternChoose.Inst.xianlan.lineCode_dic[p.portType], (x) => + { + lineRenderer.endColor = x; + }); + } + catch (Exception e) + { + Debug.Log("匹配线缆颜色错误 " + e.Message + e.StackTrace); + } + + } + + private void HexToColor(string hex, Action callback) + { + if (ColorUtility.TryParseHtmlString(hex, out Color color)) + { + callback.Invoke(color); + } + else + { + Debug.LogError("无法识别色值: " + hex); + } } /// @@ -232,6 +262,8 @@ public class CreateLine : CabinetUIBase l.lines.Add(B); l.cableGroupName = p.cableGroupName; l.cableName = p.cableName; + l.portType = p.portType; + } [ContextMenu("同行")] @@ -249,7 +281,7 @@ public class CreateLine : CabinetUIBase [ContextMenu("批量画线")] public void F7() { - for (int i = 0; i < xianLan.childCount; i++) + for (int i = xianLan.childCount - 1; i >= 0; i--) { DestroyImmediate(xianLan.GetChild(i).gameObject); } @@ -276,7 +308,7 @@ public class CreateLine : CabinetUIBase } catch (Exception e) { - Debug.Log(e.Message + e.StackTrace); + Debug.Log("批量画线错误 " + e.Message + e.StackTrace); } } diff --git a/GQ_TongXin/Assets/script/画线/LineInfor.cs b/GQ_TongXin/Assets/script/画线/LineInfor.cs index 300f82882..92334717d 100644 --- a/GQ_TongXin/Assets/script/画线/LineInfor.cs +++ b/GQ_TongXin/Assets/script/画线/LineInfor.cs @@ -16,8 +16,10 @@ public class LineInfor : MonoBehaviour public List lines = new List(); public string cableGroupName = ""; public string cableName = ""; + public string portType = ""; LineRenderer lineRenderer; + private void Awake() { lineRenderer = GetComponent(); diff --git a/GQ_TongXin/Assets/script/相机/ExtendedFlycam.cs b/GQ_TongXin/Assets/script/相机/ExtendedFlycam.cs index e9ff52d04..7fb74cfeb 100644 --- a/GQ_TongXin/Assets/script/相机/ExtendedFlycam.cs +++ b/GQ_TongXin/Assets/script/相机/ExtendedFlycam.cs @@ -371,46 +371,29 @@ public class ExtendedFlycam : MonoBehaviour /// /// 切换模式 /// - /// 是否切换视角 - public void QieHuan(Menu menu, bool iscut = true) + /// 选择状态 + public void QieHuan(Menu menu, int state = 1) { CabinetUIManager.Instance.current_menu = menu; - if (iscut) + + //菜单栏(不切换) + if (state == 1) { if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_智能巡检) - room = Room.None; + room = Room.机房; else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_现场作业) - room = Room.None; + room = Room.机房; else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_摄像头) - room = Room.None; + room = Room.机房; else - room = Room.配电室; - #region MyRegion - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_机柜容量) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_设备告警) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_温度 || - // CabinetUIManager.Instance.current_menu == Menu.M_全景监控_湿度 || - // CabinetUIManager.Instance.current_menu == Menu.M_全景监控_水浸 || - // CabinetUIManager.Instance.current_menu == Menu.M_全景监控_烟感) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_柜门状态) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_全景监控_红外监测) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_接地网) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_线缆连接_展示) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_场景管理) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_线缆连接_配置) - // room = Room.配电室; - //else if (CabinetUIManager.Instance.current_menu == Menu.M_数字孪生_线缆组配置) - // room = Room.配电室; - #endregion + room = Room.None; + showRoom(); + } + + //房间状态变(会切换) + else if (state == 2) + { if (Room.None == room) { cameraTypes = CameraTypes.全景; @@ -422,8 +405,7 @@ public class ExtendedFlycam : MonoBehaviour for (int i = 0; i < jiFang.Count; i++) { jiFang[i].SetActive(true); - } - //JingTou(((int)cameraTypes)); + } } else if (Room.机房 == room) { @@ -437,7 +419,6 @@ public class ExtendedFlycam : MonoBehaviour { jiFang[i].SetActive(false); } - //JingTou(((int)cameraTypes)); } else if (Room.配电室 == room) { @@ -451,50 +432,58 @@ public class ExtendedFlycam : MonoBehaviour { jiFang[i].SetActive(true); } - //JingTou(((int)cameraTypes)); } - JingTou(((int)cameraTypes)); } + + // 房间状态显示(无转换) else { - if (Room.None == room) - { - cameraTypes = CameraTypes.全景; - for (int i = 0; i < peiDianShi.Count; i++) - { - peiDianShi[i].SetActive(true); - } - for (int i = 0; i < jiFang.Count; i++) - { - jiFang[i].SetActive(true); - } - } - else if (Room.机房 == room) - { - cameraTypes = CameraTypes.全景; - for (int i = 0; i < peiDianShi.Count; i++) - { - peiDianShi[i].SetActive(false); - } - for (int i = 0; i < jiFang.Count; i++) - { - jiFang[i].SetActive(true); - } - } - else if (Room.配电室 == room) - { - cameraTypes = CameraTypes.全景; - for (int i = 0; i < peiDianShi.Count; i++) - { - peiDianShi[i].SetActive(true); - } - for (int i = 0; i < jiFang.Count; i++) - { - jiFang[i].SetActive(false); - } - } - JingTou(((int)cameraTypes)); + showRoom(); } } + + /// + /// 展示房间 + /// + void showRoom() + { + if (Room.None == room) + { + cameraTypes = CameraTypes.全景; + for (int i = 0; i < peiDianShi.Count; i++) + { + peiDianShi[i].SetActive(true); + } + for (int i = 0; i < jiFang.Count; i++) + { + jiFang[i].SetActive(true); + } + } + else if (Room.机房 == room) + { + cameraTypes = CameraTypes.全景; + for (int i = 0; i < peiDianShi.Count; i++) + { + peiDianShi[i].SetActive(false); + } + for (int i = 0; i < jiFang.Count; i++) + { + jiFang[i].SetActive(true); + } + } + else if (Room.配电室 == room) + { + cameraTypes = CameraTypes.全景; + for (int i = 0; i < peiDianShi.Count; i++) + { + peiDianShi[i].SetActive(true); + } + for (int i = 0; i < jiFang.Count; i++) + { + jiFang[i].SetActive(false); + } + } + JingTou(((int)cameraTypes)); + } } \ No newline at end of file