Address review

This commit is contained in:
Diavolo 2021-12-26 17:33:48 +01:00
parent 35d753406b
commit 41874769aa
No known key found for this signature in database
GPG Key ID: FA77F074E98D98A5

View File

@ -36,12 +36,6 @@ namespace Components
// like later versions of the game do
if (!trace->startsolid || elevatorSetting >= Elevators::ENABLED)
{
pml->groundTrace = *trace;
const auto fraction = trace->fraction;
ps->origin[0] += fraction * (point[0] - ps->origin[0]);
ps->origin[1] += fraction * (point[1] - ps->origin[1]);
ps->origin[2] += fraction * (point[2] - ps->origin[2]);
break;
}
}
@ -58,6 +52,13 @@ namespace Components
}
}
pml->groundTrace = *trace;
const auto fraction = trace->fraction;
ps->origin[0] += fraction * (point[0] - ps->origin[0]);
ps->origin[1] += fraction * (point[1] - ps->origin[1]);
ps->origin[2] += fraction * (point[2] - ps->origin[2]);
return 1;
}