should fix something, idk

This commit is contained in:
Jonny_Bro (Nikita) 2024-01-30 08:29:06 +05:00 committed by GitHub
parent 260a5d81ef
commit 567b647ab6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -9,7 +9,7 @@ hook.Add("EntityTakeDamage", "MEHitSounds", function(ply, dmginfo)
ply:EmitSound("mirrorsedge/Flesh_0" .. tostring(math.random(1, 9)) .. ".wav")
ply:ViewPunch(Angle(math.Rand(-10, -5), 0, math.Rand(0, 5)))
elseif dmginfo:IsFallDamage() and not ply:HasGodMode() then
elseif not ply:HasGodMode() and (dmginfo:IsFallDamage() and ply:Health() - dmginfo:GetDamage() <= 0) then
net.Start("DeathStopSound")
net.Send(ply)
@ -21,4 +21,4 @@ hook.Add("EntityTakeDamage", "MEHitSounds", function(ply, dmginfo)
ply:ScreenFade(SCREENFADE.OUT, Color(0, 0, 0, 255), 0.05, 5)
end
end)
end)