You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
897 B
30 lines
897 B
using System.Collections; |
|
using System.Collections.Generic; |
|
using UnityEngine; |
|
using UnityEngine.UI; |
|
|
|
public class LineLenghtPanel : ResourceLoadPanel<LineLenghtPanel> |
|
{ |
|
|
|
/// <summary> |
|
/// 显示管线米数方法 |
|
/// </summary> |
|
public void CheckIsLine() |
|
{ |
|
gameObject.SetActive(false); |
|
if (SelectedObjs.selectedObj != null && TheLineType(SelectedObjs.selectedObj.GetComponent<CloneGameObjInfo>().gameObjType)) |
|
{ |
|
gameObject.SetActive(true); |
|
transform.Find("Text").GetComponent<Text>().text = SelectedObjs.selectedObj.GetComponent<LineParentData>().LineLenght.ToString("0.00") + "米"; |
|
} |
|
} |
|
public bool TheLineType(CloneObjType type) |
|
{ |
|
//if (CloneObjType.OrdinaryHose == type || CloneObjType.ScintillationHose == type) |
|
//{ |
|
// return true; |
|
//} |
|
return false; |
|
} |
|
|
|
}
|
|
|