Создание урона при падении в роблокс студио

Аватар автора
Геймеры и Зомби
local MaxVelocity = script:WaitForChild("MaxFallDistance") local MinVelocity = script:WaitForChild("MinimumFallDistance") game.Players.PlayerAdded:Connect(function(Plr) Plr.CharacterAdded:Connect(function(Char) local Humanoid = Char:WaitForChild("Humanoid") local HumanoidRootPart = Char:WaitForChild("HumanoidRootPart") Humanoid.StateChanged:Connect(function(OldState, NewState) local PlrVelocity = HumanoidRootPart.Velocity.Y PlrVelocity *= -1 if PlrVelocity (Угловая скобка) MaxVelocity.Value then Humanoid.Health = 0 elseif PlrVelocity (Угловая скобка) MinVelocity.Value then Humanoid.Health -= PlrVelocity / 4 end end) end) end) 1)MaxFallDistance 2)MinimumFallDistance Когда написано ("Угловая скобка") то ставьте этот знак потому что YouTube не пропускает этот знак ¯_(ツ)_/¯

0/0


0/0

0/0

0/0