I have a script that will kick anyone who's health goes above 120. Now I want it so I can make certain people not crash when they health themselves over 120 or god themselves. This is the script:
--Variables MaxHealth = 120 --Allowed MaxHealth. If higher then player crashes.
game.Workspace.ChildAdded:connect(function(Child) -- local Humanoid = Child:findFirstChild("Humanoid") local Player = game.Players:findFirstChild(Child.Name) if Humanoid then if Player then Humanoid.Changed:connect(function() if Humanoid.Health >= Health and Humanoid.Health <= _ then else Player:Remove() end if Player and Humanoid.MaxHealth > MaxHealth then Player:Remove() end end) end end end) --