diff options
author | STRWarrior <niels.breuker@hotmail.nl> | 2014-03-29 16:00:45 +0100 |
---|---|---|
committer | STRWarrior <niels.breuker@hotmail.nl> | 2014-03-29 16:00:45 +0100 |
commit | ec4638a228edcf4c745088838e972ea07edc7cba (patch) | |
tree | 280182543c9788b7bc19bcc47c1a7ed2dc4ba3db /src/Entities/ProjectileEntity.cpp | |
parent | Fixed error when the hook gets called. (diff) | |
download | cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar.gz cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar.bz2 cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar.lz cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar.xz cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.tar.zst cuberite-ec4638a228edcf4c745088838e972ea07edc7cba.zip |
Diffstat (limited to 'src/Entities/ProjectileEntity.cpp')
-rw-r--r-- | src/Entities/ProjectileEntity.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Entities/ProjectileEntity.cpp b/src/Entities/ProjectileEntity.cpp index 07cb34f35..b724c9c55 100644 --- a/src/Entities/ProjectileEntity.cpp +++ b/src/Entities/ProjectileEntity.cpp @@ -67,6 +67,11 @@ protected: eBlockFace Face; if (bb.CalcLineIntersection(Line1, Line2, LineCoeff, Face)) { + if (cPluginManager::Get()->CallHookProjectileHitBlock(*m_Projectile)) + { + return true; + } + Vector3d Intersection = Line1 + m_Projectile->GetSpeed() * LineCoeff; m_Projectile->OnHitSolidBlock(Intersection, Face); return true; |