Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Value to TextLabel i guess?

Im trying to make a text label when your iq (leaderstat) is 100 or more Local script changes the text

Code:

local required = 100

local stat = game.Players.LocalPlayer.leaderstats.IQ

local text = script.Parent

-- Variables

stat.Changed:Connect(function()

if stat.Value >= required then

text.Text = "CODE1234"

end

end)

-- Script

1 answer

local required = 100

local stat = game:GetService("Players").LocalPlayer.leaderstats.IQ.Value

-- Variables

stat.Changed:Connect(function()

if stat.Value >= required then

game.Workspace.[PartName].[SurfaceGuiname].[TextLabelName].Text = "CODE1234"

end

end)

put this code inside a normal script and see if it works

This discussion is preserved as it was. New answers, comments, and votes are closed.