public static void SetScreenTapDisable(GameObject go) { ScreenTap comSelect = go.GetComponent <ScreenTap>(); if (comSelect != null) { ScreenTap.Destroy(comSelect); } }
public static ScreenTap SetScreenTapEnable(GameObject go) { ScreenTap comSelect = go.GetComponent <ScreenTap>(); if (comSelect == null) { comSelect = go.AddComponent <ScreenTap>(); comSelect.Search = ScreenTap.SearchType.GetComponent; } return(comSelect); }