Merge branch 'master' into feat/animation-handling

This commit is contained in:
Pavel Okhlopkov 2026-04-05 12:37:08 +03:00 committed by GitHub
commit e386fbb069
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 9 additions and 12 deletions

7
.gitmodules vendored
View file

@ -12,7 +12,6 @@
shallow = true
update = none
[submodule "extern/FidelityFX-FSR2"]
path = extern/FidelityFX-FSR2
url = https://github.com/Kelsidavis/FidelityFX-FSR2.git
shallow = true
update = none
path = extern/FidelityFX-FSR2
url = https://github.com/Kelsidavis/FidelityFX-FSR2.git
ignore = dirty

View file

@ -2547,19 +2547,17 @@ void MovementHandler::checkAreaTriggers() {
bool inside = false;
if (at.radius > 0.0f) {
// Sphere trigger — use actual radius, with small floor for very tiny triggers
float effectiveRadius = std::max(at.radius, 3.0f);
// Sphere trigger — use actual DBC radius
float dx = px - at.x;
float dy = py - at.y;
float dz = pz - at.z;
float distSq = dx * dx + dy * dy + dz * dz;
inside = (distSq <= effectiveRadius * effectiveRadius);
inside = (distSq <= at.radius * at.radius);
} else if (at.boxLength > 0.0f || at.boxWidth > 0.0f || at.boxHeight > 0.0f) {
// Box trigger — use actual size, with small floor for tiny triggers
float boxMin = 4.0f;
float effLength = std::max(at.boxLength, boxMin);
float effWidth = std::max(at.boxWidth, boxMin);
float effHeight = std::max(at.boxHeight, boxMin);
// Box trigger — use actual DBC dimensions
float effLength = at.boxLength;
float effWidth = at.boxWidth;
float effHeight = at.boxHeight;
float dx = px - at.x;
float dy = py - at.y;