I'm working on a showcase game and in real life there's a tv that plays along side the show. I've managed to get the video frame to work but I cannot get the frame to play with a script or enable the surface gui
How could I make a button that enables/disables a surface gui or enables playing for a video frame?
2 answers
WE DO NOT SUPPLY SCRIPTS
You must first attempt. And if it doesn't work, post what you have tried and we'll assist you.
Rule 2, of Website guidelines. On the Community guidelines.
Edit:
Thanks for posting your code. At the current moment it it impossible to player video frames outside of the StarterGui. But don't be disappointed yet! You can actually use adornee and keep the surfacegui in StarterGui and it will be on the part correctly.
These are previous tried scripts: 1. --function OnClicked() --if game.workspace.WALL1.TV.SurfaceGui.VideoFrame.Playing == false then -- game.workspace.WALL1.TV.SurfaceGui.VideoFrame:Play() --else -- game.workspace.WALL1.TV.SurfaceGui.VideoFrame:Stop() --end --end
--game.workspace.WALL1.TV.SurfaceGui.VideoFrame.Playing = true --wait (185) --game.workspace.WALL1.TV.SurfaceGui.VideoFrame.Playing = false --end
-- print("Hello world!") --local Character = game.Workspace.WALL1.TV.SurfaceGui --local ison = false --function switch() --if (ison == false) then --ison = true -- Character.VideoFrame.Playing = true
--game.workspace.WALL1.TV.SurfaceGui.Enabled = true
--wait (185)
--game.workspace.WALL1.TV.SurfaceGui.Enabled = false
--end
--Button = script.Parent --local TVScreen = game.Workspace.WALL1.TV:FindFirstChild("Hitbox").TVScreen
--script.Parent.MouseButton1Click:Connect(function()
--if TVScreen.Enabled == true then
-- TVScreen.Enabled = false
-- elseif TVScreen.Enabled == false then --TVScreen.Enabled = true -- end --end)
--button = script.Parent --TVScreen = game.Workspace.WALL1.TV.TVScreen
--script.Parent.MouseButton1Click:connect(function() --- if button.TVScreen.Enabled == false then -- button.TVScreen.Enabled = true -- else -- button.TVScreen.Enabled = false -- end --end)
--local VideoScreen = workspace.WALL1.TV.TVScreen -- Put location of your script you want to enable/disable --function onButtonClicked() -- VideoScreen.Disabled = false -- end -- script.Parent.MouseButton1Down:connect(onButtonClicked)
1 comment
The spacing is a bit messed up but it looks normal in the script
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
Can u show your script
Yeah I Posted As An Answer