This simple if/then statement isn't working. It also doesn't print any errors. I can't figure out what's wrong with it
local Event = game.ReplicatedStorage.Tools.GiveGun
local Gun = game.ServerStorage.Tools.Gun
Event.OnServerEvent:Connect(function(Player)
if Player.Stats.Gun.Value == false then
print("Gun isn't unlocked.")
end
end)

3 comments
Please include all operating code, like the local script that's calling the event.
Nvm I fixed it. https://developer.roblox.com/en-us/articles/Boolean
If you solved a question then put [Solved] or [Answered] in the begining or end of the question