Save Spot Script
Key RequiredUniversal

Save Spot Script

Universal ScriptYour_Local_ExploiterYour_Local_Exploiter 23.8K views 2.1K executesUpdated Oct 21, 2024
Unrated
00
Lua Script•45 lines (1264 chars)
local player = game.Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local screenGui = Instance.new("ScreenGui")
screenGui.Parent = playerGui

local button = Instance.new("TextButton")
button.Size = UDim2.new(0, 200, 0, 50)
button.Position = UDim2.new(0.5, -100, 0.5, -25)
button.Text = "Save Spot"
button.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
button.TextColor3 = Color3.fromRGB(255, 255, 255)
button.Parent = screenGui

local savedPosition = nil

local function savePosition()
    local character = player.Character or player.CharacterAdded:Wait()
    local humanoidRootPart = character:WaitForChild("HumanoidRootPart")

    savedPosition = humanoidRootPart.Position

    button.Text = "Teleport to saved spot"
end

local function teleportToSavedSpot()
    if savedPosition then
        local character = player.Character or player.CharacterAdded:Wait()
        local humanoidRootPart = character:WaitForChild("HumanoidRootPart")

        humanoidRootPart.CFrame = CFrame.new(savedPosition)

        button.Text = "Save Spot"
        savedPosition = nil
    end
end

button.MouseButton1Click:Connect(function()
    if savedPosition then
        teleportToSavedSpot()
    else
        savePosition()
    end
end)

button.Draggable = true

Features & Information

This script allows you to save a position and lets you teleport back to that saved position. The button is draggable.
#Roblox#Script#Teleportation

Community Comments (1)

SmorgasbordSmorgasbordOct 21, 2024(edited)

w script very useful

More Scripts for Universal Scripts