I'm following a guide in the devforum about DataStore settings, i did everything but don't save the settings! i'm using remote event and etc.
Ps: its not printing nothing
LocalScript:
-- declarando variaveis para o sistema
local ReplicatedStorage = game:GetService("ReplicatedStorage") -- nome da boolean
local text = script.Parent
local player = game.Players.LocalPlayer
-- localizador das arvore
local arvoreFolder = workspace:FindFirstChild("Arvores")
script.Parent.MouseButton1Click:Connect(function()
local arvore = player:WaitForChild("Settings").Arvore.Value
if arvore == false then
arvoreFolder.Parent = workspace -- Show the "Arvore" folder
text.Text = ""
ReplicatedStorage.UpdateSetting:FireServer("Arvore", true)
elseif arvore == true then
arvoreFolder.Parent = nil -- Hide the "Arvore" folder
text.Text = "X"
ReplicatedStorage.UpdateSetting:FireServer("Arvore", false)
end
end)
