This script is supposed to check your leader stats if you have more then 50 "Jumps" then it will make a button visible on a frame if you don't it want the same thing for 100 "Jumps". It works in studio but not in the game. I hope you can help me fix this :).
local Frame = script.Parent.Parent.Frame script.Parent.MouseButton1Click:Connect(function() Frame.Visible = true if game.Players.LocalPlayer.leaderstats.Jumps.Value >= 50 then script.Parent.Parent.Frame.Trail1.Visible = true else script.Parent.Parent.Frame.Trail1.Visible = false end if game.Players.LocalPlayer.leaderstats.Jumps.Value >= 100 then script.Parent.Parent.Frame.Trail1.Visible = true script.Parent.Parent.Frame.Trail2.Visible = true else script.Parent.Parent.Frame.Trail1.Visible = false script.Parent.Parent.Frame.Trail2.Visible = false end end)
To me, this would be a FilteringEnabled issue. What you're doing is making the major changes on a LocalScript, which would only work on a client-side. To combat this, It'd be best to use RemoteEvents. To show you as an example: LocalScript:
script.Parent.MouseButton1Click:Connect(function(plr) game.ReplicatedStorage.RemoteEvent:FireServer(plr) end)
ServerScript:
game.ReplicatedStorage.RemoteEvent.OnServerEvent:Connect(function(plr) print(plr.Name.." has clicked the GUI!" end)
This is an example. Don't post it into your scripts. However, try using this to help you into using the RemoteEvents to fix your issue.
its prob because its not FE compatible, to make it compatible i suggest u learn about FE