How To Make A Teleport Gui in Roblox Studio

Опубликовано: 28 Март 2026
на канале: MoreKeyHitt
103,211
1.4k

Hope This Helped!

Script -

-- Place this script inside the TextButton

local textButton = script.Parent
local part1 = game.Workspace:WaitForChild("Part1")

textButton.MouseButton1Click:Connect(function()
local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoidRootPart = character:WaitForChild("HumanoidRootPart")

-- Calculate the new position 3 studs above part1
local newPosition = part1.Position + Vector3.new(0, 3, 0)

-- Teleport the player
humanoidRootPart.CFrame = CFrame.new(newPosition)
end)

#roblox #robloxstudioscripting #tutorial #robloxstudio