-- Basic instant hide local function clickblock(event) local playerid = event.eventobjid local uiid = "6986982063319417057" -- Replace with your UI ID local elementid = "6986982063319417057_1" -- Replace with component ID -- Hide component immediately Customui:hideElement(playerid, uiid, elementid) end -- Advanced usage with fade-out local function hideWithEffect(event) local playerid = event.eventobjid Customui:hideElement(playerid, "6986982063319417057", "6986982063319417057_1", 1, 500) -- 500ms fade-out end ScriptSupportEvent:registerEvent([=[Player.ClickBlock]=], clickblock)