private void hideVideoContaier(){
CanvasGroup cg = gameObject.GetComponent();
if (cg != null) {
cg.alpha = 0f;
cg.blocksRaycasts = false; // Prevents UI from blocking raycasts
cg.interactable = false; // Prevents UI from receiving input
}
GraphicRaycaster gr = gameObject.GetComponent();
if (gr != null) gr.enabled = false;
}

Leave a Reply