No longer need nocollide sorting since they don't get added to phys_constraintsystem (#384)

This commit is contained in:
thegrb93 2022-02-02 15:37:48 -05:00 committed by GitHub
parent c95f7b65d5
commit 0877ff1bc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,7 +22,6 @@ if(SERVER)then
Slider = true,
Axis = true,
AdvBallsocket = true,
NoCollide = true,
Motor = true,
Pulley = true,
Ballsocket = true,
@ -34,11 +33,9 @@ if(SERVER)then
--Orders constraints so that the dupe uses as little constraint systems as possible
local function GroupConstraintOrder( ply, constraints )
--First seperate the nocollides, sorted, and unsorted constraints
local nocollide, sorted, unsorted = {}, {}, {}
local sorted, unsorted = {}, {}
for k, v in pairs(constraints) do
if v.Type == "NoCollide" then
nocollide[#nocollide+1] = v
elseif phys_constraint_system_types[v.Type] then
if phys_constraint_system_types[v.Type] then
sorted[#sorted+1] = v
else
unsorted[#unsorted+1] = v
@ -80,7 +77,6 @@ if(SERVER)then
end
end
buildSystems(sorted)
buildSystems(nocollide)
local ret = {}
for _, system in pairs(fullSystems) do