summaryrefslogtreecommitdiff
path: root/game/vehicles/railVehicle.cpp
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2022-10-22 19:08:24 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2022-10-22 19:08:24 +0100
commit955787485b098d51a393614cb9cfb7edd1c48bed (patch)
tree45ab665337e87c390923dc717579f96342a0d0b4 /game/vehicles/railVehicle.cpp
parentTidy network node insertion/searching (diff)
downloadilt-955787485b098d51a393614cb9cfb7edd1c48bed.tar.bz2
ilt-955787485b098d51a393614cb9cfb7edd1c48bed.tar.xz
ilt-955787485b098d51a393614cb9cfb7edd1c48bed.zip
Rename shadowing variable
Diffstat (limited to 'game/vehicles/railVehicle.cpp')
-rw-r--r--game/vehicles/railVehicle.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/game/vehicles/railVehicle.cpp b/game/vehicles/railVehicle.cpp
index ec12674..fb42a28 100644
--- a/game/vehicles/railVehicle.cpp
+++ b/game/vehicles/railVehicle.cpp
@@ -35,16 +35,16 @@ RailVehicle::intersectRay(const Ray & ray, glm::vec2 * baryPos, float * distance
constexpr const auto X = 1.35F;
const auto Y = this->rvClass->length / 2.F;
constexpr const auto Z = 3.9F;
- const auto move = glm::translate(location.pos) * rotate_ypr(location.rot);
+ const auto moveBy = glm::translate(location.pos) * rotate_ypr(location.rot);
const std::array<glm::vec3, 8> cornerVertices {{
- move * glm::vec4 {-X, Y, 0, 1}, // LFB
- move * glm::vec4 {X, Y, 0, 1}, // RFB
- move * glm::vec4 {-X, Y, Z, 1}, // LFT
- move * glm::vec4 {X, Y, Z, 1}, // RFT
- move * glm::vec4 {-X, -Y, 0, 1}, // LBB
- move * glm::vec4 {X, -Y, 0, 1}, // RBB
- move * glm::vec4 {-X, -Y, Z, 1}, // LBT
- move * glm::vec4 {X, -Y, Z, 1}, // RBT
+ moveBy * glm::vec4 {-X, Y, 0, 1}, // LFB
+ moveBy * glm::vec4 {X, Y, 0, 1}, // RFB
+ moveBy * glm::vec4 {-X, Y, Z, 1}, // LFT
+ moveBy * glm::vec4 {X, Y, Z, 1}, // RFT
+ moveBy * glm::vec4 {-X, -Y, 0, 1}, // LBB
+ moveBy * glm::vec4 {X, -Y, 0, 1}, // RBB
+ moveBy * glm::vec4 {-X, -Y, Z, 1}, // LBT
+ moveBy * glm::vec4 {X, -Y, Z, 1}, // RBT
}};
static constexpr const std::array<glm::uvec3, 10> triangles {{
// Front