From 420ac45ba17f531408f6a5d8ef5e8b7a8e3c5c3e Mon Sep 17 00:00:00 2001 From: Benau Date: Tue, 26 Mar 2019 00:25:06 +0800 Subject: [PATCH] Remove unneeded static_cast --- src/karts/kart.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/src/karts/kart.cpp b/src/karts/kart.cpp index 3f841f1c8..2569095a8 100644 --- a/src/karts/kart.cpp +++ b/src/karts/kart.cpp @@ -3233,16 +3233,15 @@ void Kart::updateGraphics(float dt) if (NetworkConfig::get()->isNetworking() && NetworkConfig::get()->isClient()) { - SmoothNetworkBody* snb = static_cast(this); - if (m_kart_animation && snb->isEnabled()) + if (m_kart_animation && SmoothNetworkBody::isEnabled()) { - snb->setEnable(false); + SmoothNetworkBody::setEnable(false); } - else if (!m_kart_animation && !snb->isEnabled()) + else if (!m_kart_animation && !SmoothNetworkBody::isEnabled()) { - snb->setEnable(true); - snb->reset(); - snb->setSmoothedTransform(getTrans()); + SmoothNetworkBody::setEnable(true); + SmoothNetworkBody::reset(); + SmoothNetworkBody::setSmoothedTransform(getTrans()); } }