summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Pickering <alexandermpickering@gmail.com>2016-06-25 18:54:21 -0400
committerAlexander Pickering <alexandermpickering@gmail.com>2016-06-25 18:54:21 -0400
commitb9a3eac2ea20b59b57234466be88ae6b4f2379db (patch)
tree5484aad6ceeaef517a742a620d97fc2ebad18a0f
parentbc4b0dbf3c305c42a6c0fa5bda492b8a786353a8 (diff)
downloadredead-b9a3eac2ea20b59b57234466be88ae6b4f2379db.tar.gz
redead-b9a3eac2ea20b59b57234466be88ae6b4f2379db.tar.bz2
redead-b9a3eac2ea20b59b57234466be88ae6b4f2379db.zip
Fixed bug where wooden objects were not detected correctly
-rw-r--r--gamemode/init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/gamemode/init.lua b/gamemode/init.lua
index 4a43b11..d6696a6 100644
--- a/gamemode/init.lua
+++ b/gamemode/init.lua
@@ -217,7 +217,7 @@ function GM:InitPostEntity()
for k,v in pairs(ents.FindByClass("prop_physics")) do
local min,max = v:WorldSpaceAABB()
local height = max.z - min.z
- if height > 10 and (not v:IsFrozen()) then
+ if height > 10 and (v:GetPhysicsObject():IsMotionEnabled()) then
table.insert(tbl,v)
end
end