Fix #3415
This commit is contained in:
parent
84359ad7da
commit
ad68f5c5ac
@ -206,7 +206,7 @@ bool Swatter::updateAndTestFinished(int ticks)
|
|||||||
float min_dist2
|
float min_dist2
|
||||||
= m_kart->getKartProperties()->getSwatterDistance();
|
= m_kart->getKartProperties()->getSwatterDistance();
|
||||||
|
|
||||||
if (dist2 < min_dist2)
|
if (dist2 < min_dist2 && !m_kart->isGhostKart())
|
||||||
{
|
{
|
||||||
// Start squashing
|
// Start squashing
|
||||||
m_animation_phase = SWATTER_TO_TARGET;
|
m_animation_phase = SWATTER_TO_TARGET;
|
||||||
@ -312,6 +312,8 @@ void Swatter::chooseTarget()
|
|||||||
void Swatter::pointToTarget()
|
void Swatter::pointToTarget()
|
||||||
{
|
{
|
||||||
#ifndef SERVER_ONLY
|
#ifndef SERVER_ONLY
|
||||||
|
if (m_kart->isGhostKart()) return;
|
||||||
|
|
||||||
if(!m_target)
|
if(!m_target)
|
||||||
{
|
{
|
||||||
m_scene_node->setRotation(core::vector3df());
|
m_scene_node->setRotation(core::vector3df());
|
||||||
@ -334,6 +336,8 @@ void Swatter::pointToTarget()
|
|||||||
*/
|
*/
|
||||||
void Swatter::squashThingsAround()
|
void Swatter::squashThingsAround()
|
||||||
{
|
{
|
||||||
|
if (m_kart->isGhostKart()) return;
|
||||||
|
|
||||||
const KartProperties *kp = m_kart->getKartProperties();
|
const KartProperties *kp = m_kart->getKartProperties();
|
||||||
|
|
||||||
AbstractKart* closest_kart = m_closest_kart;
|
AbstractKart* closest_kart = m_closest_kart;
|
||||||
|
Loading…
Reference in New Issue
Block a user