You can write your topic however you want, but you need to answer these questions:
What do you want to achieve? Keep it simple and clear!
For Quirk Buttons to get replaced upon quirk (stat) change
What is the issue? Include screenshots / videos if possible!
Players have to rejoin when they change quirk in order for buttons to get replaced.
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I’ve tried many edits/Variations of this script,
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
wait(0.5)
local plr = game.Players.LocalPlayer
local qu = plr:WaitForChild("PlayerStats",math.huge).DF
local Skill = script.Parent -- Parent is a TextButton inside a SreenGui
local uis = game:GetService("UserInputService")
if uis.TouchEnabled == true and uis.KeyboardEnabled == true then
script.Parent.Parent.Enabled = true
else
script.Parent.Parent.Enabled = true
end
for i = 1,1 do
if qu.Value == "OneForAll" then
Skill.OneForAll.Visible = true
end
if qu.Value == "Electrification" then
Skill.Electrification.Visible = true
end
if qu.Value == "DekuOneForAll" then
Skill.DekuOneForAll.Visible = true
end
end
Please do not ask people to write entire scripts or design entire systems for you. If you can’t answer the three questions above, you should probably pick a different category.
wait(0.5)
local plr = game.Players.LocalPlayer
local qu = plr:WaitForChild("PlayerStats",math.huge).DF
local Skill = script.Parent -- Parent is a TextButton inside a SreenGui
local uis = game:GetService("UserInputService")
if uis.TouchEnabled == true and uis.KeyboardEnabled == true then
script.Parent.Parent.Enabled = true
else
script.Parent.Parent.Enabled = true
end
qu.Changed:Connect(function()
if qu.Value == "OneForAll" then
Skill.OneForAll.Visible = true
end
if qu.Value == "Electrification" then
Skill.Electrification.Visible = true
end
if qu.Value == "DekuOneForAll" then
Skill.DekuOneForAll.Visible = true
end
end
So, the issue with both attempts so far is that player starts off with no buttons, then when changing quirk (stat) the buttons do not disappear to get replaced and then stack on top of each other.
local RunService = game:GetService("RunService")
RunService.RenderStepped:Connect(function()
if qu.Value == "stat1" then
Skill.stat1.Visible = true
else
Skill.stat1.Visible = false
end
-- Etc