summaryrefslogtreecommitdiffstats
path: root/src/Mobs/Monster.cpp
diff options
context:
space:
mode:
authordaniel0916 <theschokolps@gmail.com>2014-04-12 19:55:37 +0200
committerdaniel0916 <theschokolps@gmail.com>2014-04-12 19:55:37 +0200
commit2689a63e9cf61befba38a20b0bc0503070b05dfe (patch)
tree847a53356aa91ca677c9fc57e917ee9f9bd7fd6d /src/Mobs/Monster.cpp
parentFixed Bookshelves Checking (not completly) (diff)
parentUpdated the NetherFort prefabs to current Gallery contents. (diff)
downloadcuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar.gz
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar.bz2
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar.lz
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar.xz
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.tar.zst
cuberite-2689a63e9cf61befba38a20b0bc0503070b05dfe.zip
Diffstat (limited to 'src/Mobs/Monster.cpp')
-rw-r--r--src/Mobs/Monster.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Mobs/Monster.cpp b/src/Mobs/Monster.cpp
index aa6071515..171097aba 100644
--- a/src/Mobs/Monster.cpp
+++ b/src/Mobs/Monster.cpp
@@ -526,7 +526,10 @@ void cMonster::KilledBy(cEntity * a_Killer)
break;
}
}
- m_World->SpawnExperienceOrb(GetPosX(), GetPosY(), GetPosZ(), Reward);
+ if (a_Killer != NULL)
+ {
+ m_World->SpawnExperienceOrb(GetPosX(), GetPosY(), GetPosZ(), Reward);
+ }
m_DestroyTimer = 0;
}