65 lines
2.4 KiB
C#
65 lines
2.4 KiB
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
public class NPCTriggerController_10002_2002 : NPCTriggerController
|
|
{
|
|
public Device_Control_2002 device_Control;
|
|
public int chartIndex = 1;
|
|
|
|
UI_CustomSessionPanel customSessionPanel;
|
|
UI_DisassemblyAssemblyNoticePanel assemblyAssemblyNoticePanel;
|
|
// Start is called before the first frame update
|
|
protected override void OnMDown()
|
|
{
|
|
base.OnMDown();
|
|
|
|
if (device_Control != null)
|
|
{
|
|
if (!device_Control.meteringDevice.gameObject.name.Contains("原"))
|
|
{
|
|
if (!device_Control.meteringDevice.cover.cover_seal_Left.isCut && !device_Control.meteringDevice.cover.cover_seal_Right.isCut)
|
|
GameManager.UIMgr.ShowPanel<UI_DisassemblyAssemblyNoticePanel>(E_UI_Layer.Mid, (p)=>
|
|
{
|
|
//StartCoroutine(GetCustomSission());
|
|
assemblyAssemblyNoticePanel = p;
|
|
customSessionPanel = GameManager.UIMgr.GetPanel<UI_CustomSessionPanel>();
|
|
customSessionPanel.callBack += HideCustomSessionPanel;
|
|
//Button ClientContinueBtn = assemblyAssemblyNoticePanel.GetComponentInChildren<Button>();
|
|
//ClientContinueBtn.onClick.AddListener(() => {
|
|
// Debug.Log("点击了========");
|
|
//});
|
|
});
|
|
}
|
|
|
|
}
|
|
//if (GameManager.ProcessMgr.d_Scheme.CurrentProcess.CurrentSubProcess.subProcessName)
|
|
}
|
|
|
|
public void HideCustomSessionPanel(string str)
|
|
{
|
|
if (assemblyAssemblyNoticePanel != null)
|
|
{
|
|
GameManager.UIMgr.HidePanel<UI_DisassemblyAssemblyNoticePanel>();
|
|
customSessionPanel.callBack -= HideCustomSessionPanel;
|
|
}
|
|
}
|
|
|
|
//private void FixedUpdate()
|
|
//{
|
|
|
|
// if (device_Control != null)
|
|
// {
|
|
// if (npcController.speackIndex != chartIndex)
|
|
// {
|
|
// if (!device_Control.meteringDevice.gameObject.name.Contains("原"))
|
|
// {
|
|
// if (!device_Control.meteringDevice.cover.cover_seal_Left.isCut && !device_Control.meteringDevice.cover.cover_seal_Right.isCut)
|
|
// npcController.speackIndex = chartIndex;
|
|
// }
|
|
// }
|
|
// }
|
|
//}
|
|
}
|