Undertale GUI
Key RequiredUniversal

Undertale GUI

Universal ScriptLocalscriptLocalscript 2.7K views 3.5K executesUpdated Dec 31, 2025
5.0/ 5(3 votes)
30100% Positive
Lua Script•178 lines (5799 chars)
local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local StarterGui = game:GetService("StarterGui")
local TweenService = game:GetService("TweenService")
local Debris = game:GetService("Debris")

local LocalPlayer = Players.LocalPlayer
local PlayerGui = LocalPlayer:WaitForChild("PlayerGui")

local SOUND_DAMAGE_ID = "rbxassetid://4735718618"
local SOUND_HEAL_ID   = "rbxassetid://1655262564"
local SOUND_DEATH_ID  = "rbxassetid://18950593618"
local HP_DIVIDER = 5

task.spawn(function()
    while true do
        pcall(function() StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Health, false) end)
        task.wait(1)
    end
end)

local ScreenGui = PlayerGui:FindFirstChild("UndertaleHUD_Final")
if ScreenGui then ScreenGui:Destroy() end

ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "UndertaleHUD_Final"
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = PlayerGui

local MainFrame = Instance.new("Frame")
MainFrame.Name = "MainFrame"
MainFrame.Parent = ScreenGui
MainFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
MainFrame.BackgroundTransparency = 1
MainFrame.Position = UDim2.new(0, 20, 0, 10)
MainFrame.Size = UDim2.new(0, 200, 0, 50)
MainFrame.Visible = false

local NameLabel = Instance.new("TextLabel")
NameLabel.Parent = MainFrame
NameLabel.BackgroundTransparency = 1
NameLabel.Position = UDim2.new(0, 0, 0, 0)
NameLabel.Size = UDim2.new(1, 0, 0, 20)
NameLabel.Font = Enum.Font.Arcade
NameLabel.Text = LocalPlayer.DisplayName
NameLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
NameLabel.TextSize = 20
NameLabel.TextXAlignment = Enum.TextXAlignment.Left

local HealthBarBack = Instance.new("Frame")
HealthBarBack.Parent = MainFrame
HealthBarBack.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
HealthBarBack.BorderSizePixel = 0
HealthBarBack.Position = UDim2.new(0, 0, 0, 25)
HealthBarBack.Size = UDim2.new(0, 100, 0, 12)

local HealthBarFill = Instance.new("Frame")
HealthBarFill.Parent = HealthBarBack
HealthBarFill.BackgroundColor3 = Color3.fromRGB(255, 255, 0)
HealthBarFill.BorderSizePixel = 0
HealthBarFill.Size = UDim2.new(1, 0, 1, 0)

local HPText = Instance.new("TextLabel")
HPText.Parent = MainFrame
HPText.BackgroundTransparency = 1
HPText.Position = UDim2.new(0, 110, 0, 21)
HPText.Size = UDim2.new(0, 80, 0, 20)
HPText.Font = Enum.Font.Arcade
HPText.TextColor3 = Color3.fromRGB(255, 255, 255)
HPText.TextSize = 18
HPText.TextXAlignment = Enum.TextXAlignment.Left
HPText.Text = "20 / 20"

local function playSound(id)
    local s = Instance.new("Sound")
    s.SoundId = id
    s.Volume = 2
    s.Parent = workspace
    s:Play()
    Debris:AddItem(s, 5)
end

local function spawnDeathParticles(rootPart)
    local attachment = Instance.new("Attachment")
    attachment.Parent = rootPart
    
    local emitter = Instance.new("ParticleEmitter")
    emitter.Parent = attachment
    emitter.Texture = "rbxassetid://35292415"
    emitter.Color = ColorSequence.new(Color3.fromRGB(255, 0, 0))
    emitter.Size = NumberSequence.new(0.5, 0)
    emitter.Lifetime = NumberRange.new(1, 2)
    emitter.Speed = NumberRange.new(10, 20)
    emitter.SpreadAngle = Vector2.new(360, 360)
    emitter.Rate = 0
    
    emitter:Emit(50)
    
    Debris:AddItem(attachment, 3)
end

local function onCharacterAdded(char)
    MainFrame.Visible = true
    NameLabel.Text = LocalPlayer.DisplayName
    
    local hum = char:WaitForChild("Humanoid", 10)
    local root = char:WaitForChild("HumanoidRootPart", 10)
    if not hum or not root then return end

    local highlight = Instance.new("Highlight")
    highlight.Name = "UndertaleGlow"
    highlight.FillColor = Color3.fromRGB(255, 0, 0)
    highlight.OutlineColor = Color3.fromRGB(255, 255, 255)
    highlight.FillTransparency = 0.8
    highlight.OutlineTransparency = 0.5
    highlight.Parent = char

    local soul = Instance.new("Part")
    soul.Name = "Soul"
    soul.Size = Vector3.new(0.6, 0.6, 0.6)
    soul.Shape = Enum.PartType.Ball
    soul.Color = Color3.fromRGB(255, 0, 0)
    soul.Material = Enum.Material.Neon
    soul.CanCollide = false
    soul.Massless = true
    soul.Transparency = 0.1
    soul.Parent = char

    local weld = Instance.new("Weld")
    weld.Part0 = root
    weld.Part1 = soul
    weld.C0 = CFrame.new(0, 0, 0)
    weld.Parent = soul

    local lastHealth = hum.Health

    local function updateVisuals()
        local hp = math.clamp(hum.Health, 0, hum.MaxHealth)
        local maxHp = hum.MaxHealth
        local displayHP = math.ceil(hp / HP_DIVIDER)
        local displayMax = math.ceil(maxHp / HP_DIVIDER)
        
        HPText.Text = displayHP .. " / " .. displayMax
        local percent = hp / maxHp
        HealthBarFill:TweenSize(UDim2.new(percent, 0, 1, 0), "Out", "Quad", 0.15, true)
    end

    updateVisuals()

    hum.HealthChanged:Connect(function(newHealth)
        if newHealth <= 0 then
            if lastHealth > 0 then
                playSound(SOUND_DEATH_ID)
                if soul then soul:Destroy() end
                if root then spawnDeathParticles(root) end
                MainFrame.Visible = false
            end
        elseif newHealth < lastHealth then
            playSound(SOUND_DAMAGE_ID)
            local shake = TweenService:Create(MainFrame, TweenInfo.new(0.05, Enum.EasingStyle.Sine, Enum.EasingDirection.Out, 0, true), {Position = UDim2.new(0, 23, 0, 10)})
            shake:Play()
            shake.Completed:Connect(function()
                MainFrame.Position = UDim2.new(0, 20, 0, 10)
            end)
        elseif newHealth > lastHealth then
            playSound(SOUND_HEAL_ID)
        end
        
        lastHealth = newHealth
        updateVisuals()
    end)
end

if LocalPlayer.Character then
    onCharacterAdded(LocalPlayer.Character)
end

LocalPlayer.CharacterAdded:Connect(onCharacterAdded)

Features & Information

A simple script It adds hp bar from undertale, Sounds for healing and damage, Your nickname, Soul for you
#undertale#universal#deltarune#ut#gui

Community Comments (3)

MarshadowMarshadowJan 1, 2026

awesome script tbh

AintPlayinAintPlayinJan 6, 2026

Yo dude awl make this into loadstring if u want

Replying to @AintPlayin
AintPlayinAintPlayinJan 6, 2026

Since some scripts are too long for delta

More Scripts for Universal Scripts