How to make a GUI OPEN when a part is TOUCHED | Roblox Studio Tutorial

preview_player
Показать описание
In todays video I show you how to make a system where when a player touches a part a GUI opens, this type of system is used in so many different games, simulators, tycoons, obbys and even hangouts, this system is a great addition to your game to display any type of GUI. I really enjoy making these videos for you all so I hope you enjoy them just as much as I do!

Have a lovely rest of your day!

If you are a bit confused what to do, Feel free to create a ticket in my discord server and we can help you out!

Script 1: (Opening the gui)

local TouchPart = game.Workspace:WaitForChild("TouchPart") -- Change Part to whatever your part is called which a player will need to touch
local gui = script.Parent
TouchPart.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") and hit.Parent == game.Players.LocalPlayer.Character then
gui.Visible = true
print("Gui opened")
end
end)

-- Made with love by Floppy
-----------

Script 2 (Closing Script)

script.Parent.MouseButton1Click:Connect(function()
script.Parent.Parent.Visible = false
end)
-- Made with love by Floppy
-----------------------

If you would like to support me even more, Super Thanks and becoming a Member is also another way to show your appreciation!

Roblox Studio Tutorial
Roblox Studio
Studio Tutorials
Рекомендации по теме
Комментарии
Автор

floppy your the only one i watch for studio tutorials everyone else are going to fast but you do it slowly step by step, thank you

moccodev
Автор

thank you so much floppy fish you have helped me a lot. you are the only one i watch for roblox studio tutorials.

everythinggoeswithkdbella
Автор

Thank you!!! I have been wanting a script like this for a long time! You are so helpful, I can now make my game work better!! 😄

PitaBitMe
Автор

it would have worked it works in other cases but there's a error this time in output that's says appemted to index nil with chararcter can you please fix this?

chipstastegood
Автор

local fruit = game.Workspace.Part
function fu1()
= true
print("hellow world")
end
fruit.Touched:Connect(fu1)

why us my code not working the hello world is working but the gui is not visable i even checked the properties and when i tocuh the part the gui goes from not visable to visable only in properties but i cant see it like when i touch the part i see the right (✅) smth like that

Mohammed
Автор

I got an error saying
12:24:13.354 attempt to index nil with 'Character' - Server - Script:4

StebotHere
Автор

I searched youtube for a long time to find something that works and you were the only one thanks

PeanutDaBeastW
Автор

Why is it when I join the game it already shows the gui and when I press X and walk back to the gui it doesn’t show

RAS
Автор

tysm so much i watched so much tuts but none of them worked ur a life saver

DFrzzy
Автор

hay if this tutorial doesnt work turn your parts can collide off
but not can touch

Zeak_h
Автор

Hey floppy, for me it's working just once, like the GUI appears just for one time and then I can't make it again to pop up, can u help me??

MrArmin_
Автор

Thanks a lot i've been trying this and this one helped me

LightFlame.
Автор

when i need help this guy is my support! the tutorial worked floppy good

mayronmontoya
Автор

Thank you! Been looking for this lol
You streaming today?

JustEggroll
Автор

Thank you! this helped me fixed my teleporter UI!

Poggers_Studios
Автор

The reason why I LOVE using floppy for my tutorials is he has the script in the description usually! Which helps save a lot of time, and makes sure you dont get a typo!

jaykay
Автор

thank you so much you have been helping me make pretty good games thank you

kylelee
Автор

I really needed this and you are a lifesaver

NubiaOfficialRBLX
Автор

this helped me alot and you just earned yourself a new subscriber

case_Drift
Автор

No one finished watching the video right now LOL

Dum-e-