GQ_Communicate/GQ_TongXin/Assets/script/接地网/GroundingGrid.cs

50 lines
1.4 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 UnityEngine;
using System;
using System.Linq;
public class GroundingGrid : CabinetUIBase
{
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
}
public override void OnMenuChanged(Menu menu)
{
if (menu == Menu.M_Êý×ÖÂÏÉú_½ÓµØÍø)
{
gameObject.SetActive(true);
var s = Array.FindAll(TransparentGlowManage.Inst.points.ToArray(), (item) =>
{
return (item.GetComponent<TransparentGlow>() != null &&
item.name != "R08" && item.name != "R15" && item.name != "R65" &&
item.name != "R57" && item.name != "R54" && item.name != "R45" &&
item.name != "R37" && item.name != "R29" && item.name != "R22");
}).Select(item => item.GetComponent<TransparentGlow>()).ToArray();
TransparentGlowManage.Inst.transparencyALL(s);
}
else
{
gameObject.SetActive(false);
var s = Array.FindAll(TransparentGlowManage.Inst.points.ToArray(), (item) =>
{
return (item.GetComponent<TransparentGlow>() != null);
}).Select(item => item.GetComponent<TransparentGlow>()).ToArray();
TransparentGlowManage.Inst.renewALL(s);
}
}
}