ShanxiKnowledgeBase/SXElectricityInformationAcq.../Assets/taoruiqi/WorkPermit.cs

72 lines
1.6 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System.Collections;
using System.Collections.Generic;
using DefaultNamespace.ProcessMode;
using MotionFramework;
using Unity.VisualScripting;
using UnityEngine;
using UnityEngine.UI;
/// <summary>
/// 工作牌
/// </summary>
public class WorkPermit : MonoBehaviour
{
/// <summary>
/// 工作牌
/// </summary>
public GameObject WorkPermitObj;
/// <summary>
/// 对话框
/// </summary>
public Image Dialogbox;
/// <summary>
/// 对话框的text
/// </summary>
public Text DialogboxText;
/// <summary>
/// 继续按钮
/// </summary>
public Button ContinueBtn;
/// <summary>
/// 下一句话按钮
/// </summary>
public Button NextlBtn;
// Start is called before the first frame update
void Start()
{
NextlBtn.gameObject.SetActive(false);
ContinueBtn.gameObject.SetActive(true);
DialogboxText.text = null;
ContinueBtn.onClick.AddListener(() =>
{
Dialogbox.gameObject.SetActive(false);
DialogboxText.text = null;
Destroy(WorkPermitObj);
MotionEngine.GetModule<AnimationProcessManager>().HandleClick("Man_stand");
});
WorkPermitvoid();
}
void Update()
{
}
/// <summary>
/// 背包工牌按钮点击后调这个
/// </summary>
void WorkPermitvoid ()
{
WorkPermitObj.gameObject.SetActive(true);
Dialogbox.gameObject.SetActive(true);
DialogboxText.text = "我是xx供电公司工作人员这是我的工作证现在我们要对贵户进行现场检查。";
}
}