Open EngediKimHyeYoung opened 3 years ago
local playerID = script.Parent local hum = playerID:FindFirstChildWhichIsA("Humanoid")
function lavaDamage(character) if hum.FloorMaterial ~= nill then local condition = true
while condition do if hum.FloorMaterial.Name == "CrackedLava" then hum.Health = hum.Health - 1 print(hum.Health) wait(1) end condition = false end end
end
function springHeal(character) hum.Health = hum.Health + 1 print(hum.Health) end
hum.Running:Connect(lavaDamage) hum.Swimming:Connect(springHeal) print(hum.Health)
local playerID = script.Parent local hum = playerID:FindFirstChildWhichIsA("Humanoid")
function lavaDamage(character) if hum.FloorMaterial ~= nill then local condition = true
end
function springHeal(character) hum.Health = hum.Health + 1 print(hum.Health) end
hum.Running:Connect(lavaDamage) hum.Swimming:Connect(springHeal) print(hum.Health)