Fix multiple nails stopping constraints being removed on dead prop.
Addresses https://github.com/JetBoom/zombiesurvival/issues/100
This commit is contained in:
parent
1140463eba
commit
77fea51273
1 changed files with 1 additions and 1 deletions
|
@ -391,7 +391,7 @@ function meta:RemoveNail(nail, dontremoveentity, removedby)
|
|||
local cons = nail:GetNailConstraint()
|
||||
local othernails = 0
|
||||
for _, othernail in pairs(ents.FindByClass("prop_nail")) do
|
||||
if othernail ~= nail and othernail:GetNailConstraint():IsValid() and othernail:GetNailConstraint() == cons then
|
||||
if othernail ~= nail and not nail.m_IsRemoving and othernail:GetNailConstraint():IsValid() and othernail:GetNailConstraint() == cons then
|
||||
othernails = othernails + 1
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue