diff options
Diffstat (limited to 'game/network')
-rw-r--r-- | game/network/rail.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/game/network/rail.cpp b/game/network/rail.cpp index 0cb2725..1f432cb 100644 --- a/game/network/rail.cpp +++ b/game/network/rail.cpp @@ -155,7 +155,7 @@ RailLinkCurve::RailLinkCurve(const NodePtr & a, const NodePtr & b, glm::vec3 c, const auto step {glm::vec3 {-arc_length(arc), e0p.y - e1p.y, slength} / segs}; const auto trans {glm::translate(centreBase)}; - int segCount = segs; + auto segCount = std::lround(segs); std::vector<Vertex> vertices; vertices.reserve((segCount + 1) * railCrossSection.size()); for (glm::vec3 swing = {arc.second, e1p.y - centreBase.y, 0.F}; segCount >= 0; swing += step, --segCount) { |