diff --git a/src/ObjLoading/Game/IW4/PhysPreset/InfoStringLoaderPhysPresetIW4.cpp b/src/ObjLoading/Game/IW4/PhysPreset/InfoStringLoaderPhysPresetIW4.cpp index 159fbd88..c71d4726 100644 --- a/src/ObjLoading/Game/IW4/PhysPreset/InfoStringLoaderPhysPresetIW4.cpp +++ b/src/ObjLoading/Game/IW4/PhysPreset/InfoStringLoaderPhysPresetIW4.cpp @@ -45,7 +45,7 @@ namespace physPreset.bounce = physPresetInfo.bounce; if (physPresetInfo.isFrictionInfinity != 0) - physPreset.friction = std::numeric_limits::infinity(); + physPreset.friction = std::numeric_limits::max(); else physPreset.friction = physPresetInfo.friction; diff --git a/src/ObjWriting/Game/IW4/PhysPreset/PhysPresetInfoStringDumperIW4.cpp b/src/ObjWriting/Game/IW4/PhysPreset/PhysPresetInfoStringDumperIW4.cpp index 7df7ebee..bd734f92 100644 --- a/src/ObjWriting/Game/IW4/PhysPreset/PhysPresetInfoStringDumperIW4.cpp +++ b/src/ObjWriting/Game/IW4/PhysPreset/PhysPresetInfoStringDumperIW4.cpp @@ -37,7 +37,7 @@ namespace physPresetInfo->mass = physPreset->mass; physPresetInfo->bounce = physPreset->bounce; - if (std::isinf(physPreset->friction)) + if (physPreset->friction >= std::numeric_limits::max()) { physPresetInfo->isFrictionInfinity = 1; physPresetInfo->friction = 0;