So I was messing around on roblox studio, i'm trying to make a thriller/horror with voiceovers and everything. Here's my main problem though... I made a click detector on a part (which in the game is like a page) and when you click it, it pops up the Gui (where you can read the page). Thing is though I don't want people to be able to exit it whenever they want because I'm going to add a voice over reading the note. So how would I make it (depending on how ever long the voice over is) close after that time period? Here's the script
function onClick(click)
for i,v in pairs (script.Parent:GetChildren()) do
if v.ClassName == "ScreenGui" then
c = v:Clone()
c.Parent = click.PlayerGui
end
end
end
script.Parent.ClickDetector.MouseClick:connect(onClick)
