Hey, guys I am having some issues with FilteringEnabled I am using a ServerScript one inside of data storage and one inside of the TextButtons however, the FilteringEnabled is still not letting it work here is my script inside of the TextButton:
script.Parent.MouseButton1Click:connect(function()
local plr = script.Parent.Parent.Parent.Parent.Parent
local char = plr.Character
local stats = plr:WaitForChild("Stats")
local defense = stats:WaitForChild("Defense")
defense.Value = defense.Value + 50
local message = Instance.new("Hint")
message.Text = char.Name.."'s Defense is: "..defense.Value
message.Parent = workspace
wait(5)
message:remove()
end)
If you guys need my ServerScript inside of ServerScriptService please tell me in the comment below because that's the script that is using Data Storage and all that.... However the problem is that nothing happens when I click on the Gui so I am thinking I did something wrong here on this script!
Thank you and I hope someone can answer this question!
~~ KingLoneCat

1 comment
all scripts on the client side should be in local scripts. also get plr from >game.Players.LocalPlayer