So, I was creating a script that could calculate a certain height and, if the character exceeds that limit, life could decrease or remove, so, in my brilliant mind, well not totally I did it like:
local player = game.Players.LocalPlayer
local char = player.Character
while wait() do
if char.HumanoidRootPart.Position.Y < 1000 then
char.Humanoid.Health = 0
end
end
I believe that this command is not the right command because, I tested it and it didn't work the way I wanted. So how can I solve this little problem?

2 comments
You talk in a really flowery way, lol
Haha thank you, I got what I wanted, I've put together the necessary script, thanks for the feedback.