if script.Parent.Parent.A.Transparency==1 then
game.StarterGui.ScreenGui.h.Text = game.StarterGui.ScreenGui.h.Text - "20"
game.Players.LocalPlayer:WaitForChild("PlayerGui"):WaitForChild("ScreenGui").hunger.Size =
UDim2.new(0,game.StarterGui.ScreenGui.h.Text,0,0)
...is what i used

2 comments
You said your using a click detector? Is this clicking a part or a text button?
part