mirror of
https://github.com/GTNewHorizons/BloodMagic.git
synced 2026-11-21 04:22:29 +00:00
Avoided potential crash when Botania isn't installed.
This commit is contained in:
1 parent
f7b552a3c7
commit
03f03f1ad3
1 file changed
+8
-1
+8
-1
@@ -35,6 +35,7 @@ import cpw.mods.fml.common.ObfuscationReflectionHelper;
|
||||
import cpw.mods.fml.common.eventhandler.Event.Result;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.PlayerEvent.PlayerRespawnEvent;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
|
||||
public class AlchemicalWizardryEventHooks
|
||||
{
|
||||
@@ -322,7 +323,7 @@ public class AlchemicalWizardryEventHooks
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!(projectile instanceof IProjectile) || (projectile instanceof IManaBurst))
|
||||
if (!(projectile instanceof IProjectile) || (AlchemicalWizardry.isBotaniaLoaded && isManaBurst(projectile)))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
@@ -474,4 +475,10 @@ public class AlchemicalWizardryEventHooks
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Optional.Method(modid = "Botania")
|
||||
private boolean isManaBurst(Entity projectile)
|
||||
{
|
||||
return projectile instanceof IManaBurst;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user