From fd95d49fd495903f8dfb705196f0558bdb3475ce Mon Sep 17 00:00:00 2001 From: chenxiangxue <910695411@qq.com> Date: Wed, 21 Aug 2024 17:07:46 +0800 Subject: [PATCH] =?UTF-8?q?=E8=9E=BA=E4=B8=9D=E7=9B=96=E5=AD=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../FirstPersonController.cs | 2 +- .../Prefabs/Objects/Tools/万用表.prefab | 4 +- Assets/Scenes/05_LiveScene.unity | 131 +++++++++--------- .../直接接入式电能计量装置/Device_Cover.cs | 13 +- .../Device_DirectAccessElectricEnergyMeteringDevice.cs | 9 -- .../Device_NamePlate.cs | 7 + Assets/Scripts/CXX/Tools/Tool_Screw.cs | 90 +++++++----- Assets/Scripts/CXX/Tools/Tool_Screwdriver.cs | 8 +- 8 files changed, 143 insertions(+), 121 deletions(-) diff --git a/Assets/Plugins/ModularFirstPersonController/FirstPersonController/FirstPersonController.cs b/Assets/Plugins/ModularFirstPersonController/FirstPersonController/FirstPersonController.cs index c8fcdad..bcb506f 100644 --- a/Assets/Plugins/ModularFirstPersonController/FirstPersonController/FirstPersonController.cs +++ b/Assets/Plugins/ModularFirstPersonController/FirstPersonController/FirstPersonController.cs @@ -210,7 +210,7 @@ public class FirstPersonController : MonoBehaviour private void Update() { float scrollValue=Input.GetAxis("Mouse ScrollWheel"); - playerCamera.fieldOfView = Mathf.Clamp(playerCamera.fieldOfView - scrollValue * 20, 20, 60); + playerCamera.fieldOfView = Mathf.Clamp(playerCamera.fieldOfView - scrollValue * 20, 10, 60); #region Camera diff --git a/Assets/Resources/Prefabs/Objects/Tools/万用表.prefab b/Assets/Resources/Prefabs/Objects/Tools/万用表.prefab index 29ac1a9..528b7f8 100644 --- a/Assets/Resources/Prefabs/Objects/Tools/万用表.prefab +++ b/Assets/Resources/Prefabs/Objects/Tools/万用表.prefab @@ -542,7 +542,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 6007338389148380660} m_LocalRotation: {x: -0.7071068, y: 0, z: -0, w: 0.7071068} - m_LocalPosition: {x: 0.0077809426, y: 0.041037444, z: 0.052813787} + m_LocalPosition: {x: 0.026, y: 0.041037444, z: 0.0528} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] @@ -888,7 +888,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 8218722650585021723} m_LocalRotation: {x: -0.7071068, y: 0, z: -0, w: 0.7071068} - m_LocalPosition: {x: 0.0077809426, y: 0.041037444, z: 0.052813787} + m_LocalPosition: {x: -0.0114, y: 0.041037444, z: 0.0528} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] diff --git a/Assets/Scenes/05_LiveScene.unity b/Assets/Scenes/05_LiveScene.unity index ab74472..5c0c2a7 100644 --- a/Assets/Scenes/05_LiveScene.unity +++ b/Assets/Scenes/05_LiveScene.unity @@ -534,14 +534,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 174907860} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2512615080652099258} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &363627258 GameObject: m_ObjectHideFlags: 0 @@ -565,14 +565,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 363627258} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5005034008878831860} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!114 &461888413 MonoBehaviour: m_ObjectHideFlags: 0 @@ -629,14 +629,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 489835677} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: 0, y: -1, z: 0, w: 0} m_LocalPosition: {x: 0, y: 0, z: 0.477} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 854447323} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 180, y: 0, z: 180} --- !u!1 &518629441 GameObject: m_ObjectHideFlags: 0 @@ -660,14 +660,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 518629441} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 6188379750967134744} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!114 &537037209 MonoBehaviour: m_ObjectHideFlags: 0 @@ -740,14 +740,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 569815579} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00407, z: -0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2186015853919517684} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &671244651 GameObject: m_ObjectHideFlags: 0 @@ -771,14 +771,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 671244651} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} m_LocalPosition: {x: 0, y: -0.002, z: -0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 772408090424556368} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &722641425 GameObject: m_ObjectHideFlags: 0 @@ -802,14 +802,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 722641425} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2818445645679545286} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &745566541 GameObject: m_ObjectHideFlags: 0 @@ -833,14 +833,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 745566541} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 6335132133427796312} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!114 &763732789 MonoBehaviour: m_ObjectHideFlags: 0 @@ -890,6 +890,10 @@ MonoBehaviour: deviceType: 6 isOpen: 0 isCheckOK: 0 + cover_screw_Left: {fileID: 839453759} + cover_screw_Right: {fileID: 461888413} + cover_seal_Left: {fileID: 763732789} + cover_seal_Right: {fileID: 537037209} --- !u!64 &773927539 MeshCollider: m_ObjectHideFlags: 0 @@ -927,14 +931,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 798370971} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5947998414568147115} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!114 &839453759 MonoBehaviour: m_ObjectHideFlags: 0 @@ -1281,14 +1285,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 877711205} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 3012151823388690702} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &945203828 GameObject: m_ObjectHideFlags: 0 @@ -1312,14 +1316,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 945203828} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00361, z: -0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 9154388617798714763} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1015865458 GameObject: m_ObjectHideFlags: 0 @@ -1343,14 +1347,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1015865458} - m_LocalRotation: {x: 0.87032646, y: -0, z: -0, w: 0.49247515} + m_LocalRotation: {x: 0, y: 0.5, z: 0.8660254, w: 0} m_LocalPosition: {x: -0.722, y: 0, z: -0.379} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5307496774079708624} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 120.993, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -60, y: 0, z: 180} --- !u!1 &1032002449 GameObject: m_ObjectHideFlags: 0 @@ -1374,14 +1378,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1032002449} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5909821145515160780} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1063285401 GameObject: m_ObjectHideFlags: 0 @@ -1695,14 +1699,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1121939183} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 7493674861726287250} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1229670287 GameObject: m_ObjectHideFlags: 0 @@ -2061,14 +2065,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1288299913} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 64141901573983753} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1001 &1501092961 PrefabInstance: m_ObjectHideFlags: 0 @@ -2157,14 +2161,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1530165943} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 3225610877961321162} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1570333641 GameObject: m_ObjectHideFlags: 0 @@ -2188,14 +2192,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1570333641} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1794869921580814865} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1605182328 GameObject: m_ObjectHideFlags: 0 @@ -2219,14 +2223,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1605182328} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} m_LocalPosition: {x: 0, y: -0.00168, z: 0.00241} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1063285405} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &1646418508 GameObject: m_ObjectHideFlags: 0 @@ -2250,14 +2254,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1646418508} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1756217935758852} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!114 &1671670083 MonoBehaviour: m_ObjectHideFlags: 0 @@ -2278,7 +2282,6 @@ MonoBehaviour: cabinetDoor: {fileID: 1671670084} socket: {fileID: 854447327} inSwitch: {fileID: 1276731515} - seal: {fileID: 0} --- !u!114 &1671670084 MonoBehaviour: m_ObjectHideFlags: 0 @@ -2317,10 +2320,6 @@ MonoBehaviour: deviceType: 3 namePlate: {fileID: 1805486864} cover: {fileID: 773927538} - cover_screw_Left: {fileID: 839453759} - cover_screw_Right: {fileID: 461888413} - cover_seal_Left: {fileID: 763732789} - cover_seal_Right: {fileID: 537037209} jieXian_lines: - {fileID: 7264596684256352003} - {fileID: 9127358232238645829} @@ -2732,14 +2731,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1829404698} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5293166949573323979} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1870915212 GameObject: m_ObjectHideFlags: 0 @@ -2763,14 +2762,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1870915212} - m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} m_LocalPosition: {x: 0, y: -0.00063, z: -0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2087449995448212415} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &1924810267 GameObject: m_ObjectHideFlags: 0 @@ -2794,14 +2793,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1924810267} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 8066631825252621433} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &1944487945 GameObject: m_ObjectHideFlags: 0 @@ -2825,14 +2824,14 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1944487945} - m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0.7071068, w: 0} m_LocalPosition: {x: 0, y: -0.00231, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 8122731532833999652} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 180} --- !u!1 &2124423728 GameObject: m_ObjectHideFlags: 0 @@ -4506,7 +4505,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 0 + m_IsActive: 1 --- !u!4 &1662390741567743938 Transform: m_ObjectHideFlags: 0 @@ -4897,7 +4896,7 @@ GameObject: - component: {fileID: 7493674861726287252} - component: {fileID: 7493674861726287253} m_Layer: 0 - m_Name: "\u96F6in_\u87BA\u4E1D\u4E0B" + m_Name: "\u96F6out_\u87BA\u4E1D\u4E0B" m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -4917,7 +4916,7 @@ Transform: m_Children: - {fileID: 569815580} m_Father: {fileID: 6145003456572704199} - m_RootOrder: 4 + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!23 &2229436844603107480 MeshRenderer: @@ -5336,7 +5335,7 @@ GameObject: - component: {fileID: 5293166949573323981} - component: {fileID: 5293166949573323982} m_Layer: 0 - m_Name: "\u96F6in_\u87BA\u4E1D\u4E0A" + m_Name: "\u96F6out_\u87BA\u4E1D\u4E0A" m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -7904,7 +7903,7 @@ GameObject: - component: {fileID: 8934923622274209728} - component: {fileID: 8934923622274209727} m_Layer: 0 - m_Name: "\u96F6out_\u87BA\u4E1D\u4E0A" + m_Name: "\u96F6in_\u87BA\u4E1D\u4E0A" m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -8025,7 +8024,7 @@ GameObject: - component: {fileID: 5503775857445437771} - component: {fileID: 5503775857445437770} m_Layer: 0 - m_Name: "\u96F6out_\u87BA\u4E1D\u4E0B" + m_Name: "\u96F6in_\u87BA\u4E1D\u4E0B" m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -8736,10 +8735,10 @@ Transform: m_ConstrainProportionsScale: 0 m_Children: - {fileID: 9154388617798714763} + - {fileID: 2186015853919517684} - {fileID: 8046855924957279297} - {fileID: 7901662567069841988} - {fileID: 8221555516644558398} - - {fileID: 2186015853919517684} - {fileID: 1913972820797242095} - {fileID: 8636386138143834533} - {fileID: 7405062064322509446} @@ -9855,8 +9854,8 @@ MonoBehaviour: isConnected: 1 id: screws: - - {fileID: 8934923622274209726} - - {fileID: 5503775857445437769} + - {fileID: 5293166949573323980} + - {fileID: 7493674861726287251} --- !u!4 &6987732811968612499 Transform: m_ObjectHideFlags: 0 @@ -12705,7 +12704,7 @@ Transform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 6145003456572704199} - m_RootOrder: 2 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &7902199384183518645 GameObject: @@ -13056,8 +13055,8 @@ MonoBehaviour: isConnected: 1 id: screws: - - {fileID: 5293166949573323980} - - {fileID: 7493674861726287251} + - {fileID: 8934923622274209726} + - {fileID: 5503775857445437769} --- !u!4 &8004374623588391102 Transform: m_ObjectHideFlags: 0 @@ -13086,7 +13085,7 @@ Transform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 6145003456572704199} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!33 &8058973288971063312 MeshFilter: @@ -13182,7 +13181,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 0 + m_IsActive: 1 --- !u!114 &8080430218902094478 MonoBehaviour: m_ObjectHideFlags: 0 @@ -13605,7 +13604,7 @@ Transform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 6145003456572704199} - m_RootOrder: 3 + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!33 &8249789167346075976 MeshFilter: diff --git a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_Cover.cs b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_Cover.cs index 480c435..2c5bba7 100644 --- a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_Cover.cs +++ b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_Cover.cs @@ -18,6 +18,16 @@ public class Device_Cover : Device_Base /// public bool isCheckOK; + + [Tooltip("˿")] + public Tool_Screw cover_screw_Left; + [Tooltip("Ҹ˿")] + public Tool_Screw cover_screw_Right; + [Tooltip("ӷӡ")] + public Device_Seal cover_seal_Left; + [Tooltip("Ҹӷӡ")] + public Device_Seal cover_seal_Right; + private void OnMouseDown() { Debug.Log(""); @@ -25,8 +35,7 @@ public class Device_Cover : Device_Base if(!isOpen) { - Device_DirectAccessElectricEnergyMeteringDevice deemd= transform.parent.GetComponent(); - if (!deemd.cover_screw_Left.isInstall && !deemd.cover_screw_Right.isInstall) + if (!cover_screw_Left.isInstall && !cover_screw_Right.isInstall) { Open(); } diff --git a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_DirectAccessElectricEnergyMeteringDevice.cs b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_DirectAccessElectricEnergyMeteringDevice.cs index 06389ad..f1ceb7c 100644 --- a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_DirectAccessElectricEnergyMeteringDevice.cs +++ b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_DirectAccessElectricEnergyMeteringDevice.cs @@ -18,15 +18,6 @@ public class Device_DirectAccessElectricEnergyMeteringDevice : Device_Base /// public Device_Cover cover; - [Tooltip("˿")] - public Tool_Screw cover_screw_Left; - [Tooltip("Ҹ˿")] - public Tool_Screw cover_screw_Right; - [Tooltip("ӷӡ")] - public Device_Seal cover_seal_Left; - [Tooltip("Ҹӷӡ")] - public Device_Seal cover_seal_Right; - /// /// ܱ diff --git a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_NamePlate.cs b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_NamePlate.cs index 8028075..c285941 100644 --- a/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_NamePlate.cs +++ b/Assets/Scripts/CXX/Devices/直接接入式电能计量装置/Device_NamePlate.cs @@ -42,6 +42,13 @@ public class Device_NamePlate : Device_Base { Debug.Log("˲"); isChecked = true; + if (GameManager.UIMgr != null) + { + GameManager.UIMgr.ShowPanel(E_UI_Layer.System, (panel) => + { + panel.Init($"{""}:{""}", $"{"˶Ժͳ¼ɣ"}"); + }); + } } }); } diff --git a/Assets/Scripts/CXX/Tools/Tool_Screw.cs b/Assets/Scripts/CXX/Tools/Tool_Screw.cs index 46bf45b..69db93b 100644 --- a/Assets/Scripts/CXX/Tools/Tool_Screw.cs +++ b/Assets/Scripts/CXX/Tools/Tool_Screw.cs @@ -22,18 +22,23 @@ public class Tool_Screw : Tool_Base /// public Transform installPos; /// - /// Ƿ + /// Ƿ /// public bool hasElectricity; /// - /// ˿šʱλ + /// ƶܲ /// - private float localYInstallValue; - /// - /// ˿šʱλ - /// - private float localYUnInstallValue; + private bool isMoving; + + ///// + ///// ˿šʱλ + ///// + //private float localYInstallValue; + ///// + ///// ˿šʱλ + ///// + //private float localYUnInstallValue; protected override void OnAwake() @@ -49,21 +54,28 @@ public class Tool_Screw : Tool_Base /// public void BeInstalled(Tool_Screwdriver screwdriver) { - //˿ʼλ - screwdriver.transform.position = installPos.position; - // - transform.DOLocalMoveY(transform.localPosition.y+0.02f, 1) - .OnUpdate(() => - { - transform.RotateAroundLocal(Vector3.up, 1); - screwdriver.transform.position = installPos.position; - screwdriver.transform.eulerAngles = transform.eulerAngles; - }) - .OnComplete(() => - { - Debug.Log("˿š"); - isInstall = true; - }); + if (!isMoving) + { + isMoving = true; + Debug.Log("ʼš˿"); + //˿ʼλ + screwdriver.transform.position = installPos.position; + // + transform.DOLocalMoveY(transform.localPosition.y + 0.02f, 1) + .OnUpdate(() => + { + transform.RotateAroundLocal(Vector3.up, 1); + screwdriver.transform.position = installPos.position; + screwdriver.transform.eulerAngles = transform.eulerAngles; + Debug.Log(screwdriver.transform.eulerAngles); + }) + .OnComplete(() => + { + Debug.Log("˿š"); + isInstall = true; + isMoving = false; + }); + } } /// @@ -72,19 +84,25 @@ public class Tool_Screw : Tool_Base /// public void BeUnInstalled(Tool_Screwdriver screwdriver) { - //˿ʼλ - screwdriver.transform.position = installPos.position; - // - transform.DOLocalMoveY(transform.localPosition.y - 0.02f, 1) - .OnUpdate(() => - { - transform.RotateAroundLocal(Vector3.up, 1); - screwdriver.transform.position = installPos.position; - }) - .OnComplete(() => - { - Debug.Log("˿š"); - isInstall = false; - }); + if (!isMoving) + { + isMoving = true; + Debug.Log("ʼж˿"); + //˿ʼλ + screwdriver.transform.position = installPos.position; + // + transform.DOLocalMoveY(transform.localPosition.y - 0.02f, 1) + .OnUpdate(() => + { + transform.RotateAroundLocal(Vector3.up, 1); + screwdriver.transform.position = installPos.position; + }) + .OnComplete(() => + { + Debug.Log("˿š"); + isInstall = false; + isMoving = false; + }); + } } } diff --git a/Assets/Scripts/CXX/Tools/Tool_Screwdriver.cs b/Assets/Scripts/CXX/Tools/Tool_Screwdriver.cs index 99fdd07..5224eb8 100644 --- a/Assets/Scripts/CXX/Tools/Tool_Screwdriver.cs +++ b/Assets/Scripts/CXX/Tools/Tool_Screwdriver.cs @@ -16,7 +16,6 @@ public class Tool_Screwdriver : Tool_Base { if (!screw.isInstall) { - Debug.Log("ʼš˿"); screw.BeInstalled(this); } } @@ -29,7 +28,6 @@ public class Tool_Screwdriver : Tool_Base { if (screw.isInstall ) { - Debug.Log("ʼж˿"); screw.BeUnInstalled(this); } } @@ -42,17 +40,17 @@ public class Tool_Screwdriver : Tool_Base Ray tmpray = Camera.main.ScreenPointToRay(Input.mousePosition); if (Physics.Raycast(tmpray, out RaycastHit hit)) { - // + //˿ Tool_Screw ts = hit.transform.GetComponent(); if (ts != null) { - if(ts.id== "ܱӹ̶˿1" && !Device_DirectAccessElectricEnergyMeteringDevice.instance.cover_seal_Left.isCut) + if(ts.id== "ܱӹ̶˿1" && !Device_DirectAccessElectricEnergyMeteringDevice.instance.cover.cover_seal_Left.isCut) { Debug.Log("ӡδ"); return; } - if (ts.id == "ܱӹ̶˿2" && !Device_DirectAccessElectricEnergyMeteringDevice.instance.cover_seal_Right.isCut) + if (ts.id == "ܱӹ̶˿2" && !Device_DirectAccessElectricEnergyMeteringDevice.instance.cover.cover_seal_Right.isCut) { Debug.Log("ӡδ"); return;