-
What do you want to achieve?
i want the if statment to check if the value = item -
What is the issue?
it doesnt do even if its conditon is met -
What solutions have you tried so far?
tried to print to see the issue and as it turns out the if statment doesnt allow the script to run as intended
local check = script.Parent.Open
local stuff = {"MysteryClick", "DeathClick"}
local page = game.Players.LocalPlayer.PlayerGui.ShopGui.Pages.OwnedItemsPage
check.Changed:Connect(function(value)
local items = game.Players.LocalPlayer.ToolFolder:GetChildren()
if value == true then
for index , Value in ipairs(items) do
print(Value)
for num , item in ipairs(stuff) do
print(item)
if Value == item then
if Value.Value == true then
page:FindFirstChild(item).Visible = true
end
end
end
end
end
end)
by the way i check if the item and value are the same by printing and they are but the if statment still doesnt allow it