From 1ae8ef7d942f72b0d91fe3f14a73104e8e868143 Mon Sep 17 00:00:00 2001 From: huqibin <762612145@qq.com> Date: Tue, 21 Jan 2025 11:07:26 +0800 Subject: [PATCH] 0121 --- .../10009_9001_04_ToolMaterialScene.unity | 8 ++++++ Assets/Scripts/StepState_9001.cs | 27 ++++++++++++------- 2 files changed, 26 insertions(+), 9 deletions(-) diff --git a/Assets/Scenes/10009_9001_04_ToolMaterialScene.unity b/Assets/Scenes/10009_9001_04_ToolMaterialScene.unity index f2e099d..aafee57 100644 --- a/Assets/Scenes/10009_9001_04_ToolMaterialScene.unity +++ b/Assets/Scenes/10009_9001_04_ToolMaterialScene.unity @@ -8867,6 +8867,10 @@ PrefabInstance: propertyPath: m_LocalEulerAnglesHint.z value: 0 objectReference: {fileID: 0} + - target: {fileID: 1508266232694078962, guid: 906cc253ee10599478864236a349d004, type: 3} + propertyPath: m_LocalPosition.y + value: 1.577 + objectReference: {fileID: 0} - target: {fileID: 5370190688320940380, guid: 906cc253ee10599478864236a349d004, type: 3} propertyPath: m_IsActive value: 0 @@ -8895,6 +8899,10 @@ PrefabInstance: propertyPath: m_IsActive value: 1 objectReference: {fileID: 0} + - target: {fileID: 9208951480293848064, guid: 906cc253ee10599478864236a349d004, type: 3} + propertyPath: m_LocalPosition.y + value: 1.572 + objectReference: {fileID: 0} m_RemovedComponents: - {fileID: 4487972598169150845, guid: 906cc253ee10599478864236a349d004, type: 3} - {fileID: 6573384303805956468, guid: 906cc253ee10599478864236a349d004, type: 3} diff --git a/Assets/Scripts/StepState_9001.cs b/Assets/Scripts/StepState_9001.cs index 2a29b99..cd8c1f3 100644 --- a/Assets/Scripts/StepState_9001.cs +++ b/Assets/Scripts/StepState_9001.cs @@ -65,6 +65,24 @@ public class StepState_9001 : StepState else if (num == 3) { Score_9001.cdzIndex = 0; + + //清空背包数据 + PacksackBagMgr.Instance.ClearAllData(); + //生成服装 + List items = ToolAndmaterialMgr.Instance.CreateItemInfoByName(new List { "国网安全帽", "工作服", "绝缘手套", "绝缘靴" }); + //放入背包 + items.ForEach(item => + { + PacksackBagMgr.Instance.AddOneToolOrMater(item); + //穿上 + PacksackBagMgr.Instance.WearItemState(item, true); + }); + //生成工具 + List items2 = ToolAndmaterialMgr.Instance.CreateItemInfoByName(new List { "剥线钳", "绝缘铲", "验电笔", "国网安全帽", "工作服", "绝缘手套", "绝缘靴", "工作证", "盒装封印", "绝缘胶带", "三相四线费控智能电能表", "盒装计量箱电子标签" }); + items2.ForEach(item => + { + PacksackBagMgr.Instance.AddOneToolOrMater(item); + }); } else if (num == 4)//验电 { @@ -88,19 +106,10 @@ public class StepState_9001 : StepState device_Control.InitEWM(); - //Device_Control_9001.EWM_OBJ = device_Control.ewmh; - //device_Control.ewm.SetActive(false); - //device_Control.ewmh.SetActive(true); - //Device_Control_9001.ewmOK = false; - //Device_Control_9001.isSMOK = false; - //if (Device_Control_9001.EWM_OBJ != null && Device_Control_9001.EWM_OBJ.GetComponent() != null) - //Device_Control_9001.EWM_OBJ.GetComponent().isInstall = true; - Score_9001.cdzIndex = 0; } else if (num == 5)//扫描二维码 { - Score_9001.cdzIndex = 0; } else if (num == 6)//移除损坏二维码