So I’m making a gui. But the problem is, I made the problems and locked screen, and I don’t know how to make it so the game checks if a player has a required amount of stats. In this case, the stats name is “kills”
When you have the amount of kills needed, the locked gui will disappear and allow you to click the buttons behind it. No subtracting stats value like doors.
Edit: disappear by itself or needs manual click to disappear.
Well, if you’ve already made the leaderstats & it’s in a PlayerAdded event, you could just reference the Player’s GUI, use a Changed event to detect if the player has enough “Kills”, then disable the GUI if they do
local requiredKills = 10
-- This is where you change the kills for whenever you get a kill
if(plr.leaderstats.Kills.Value > requiredKills ) then
-- Reference the gui here and make it visbile
end