When the EntityBullet checks for potential hits, some entites are excluded so that they can be passed through/ignored. This change aims at expanding the list of these entites.
any class implementing IProjectile needs to be excluded since many other mods use IProjectile for their projectiles.
This was done by replacing !(entity instanceof EntityXPOrb) && !(entity instanceof EntityArrow) by !(entity instanceof IProjectile) since these two already implement IProjectile.
To make sure potential subclasses of EntityBullet are excluded (I used a subclass in my NPC vehicles mod) entity != this was replaced by !(entity instanceof EntityBullet) which is a broader clause that is not entirely covered by !entity.getClass().toString().contains("flansmod.") since subclasses of EntityBullet can exist outside of the "flansmod" package.
Intended usage in Content Packs/Users of the mod
Nothing changed here.
Compatibility
More Stability and Better Compatibility with other mods by taking more use cases with projectiles into account.
Description of changes
When the EntityBullet checks for potential hits, some entites are excluded so that they can be passed through/ignored. This change aims at expanding the list of these entites.
!(entity instanceof EntityXPOrb) && !(entity instanceof EntityArrow)
by!(entity instanceof IProjectile)
since these two already implement IProjectile.entity != this
was replaced by!(entity instanceof EntityBullet)
which is a broader clause that is not entirely covered by!entity.getClass().toString().contains("flansmod.")
since subclasses of EntityBullet can exist outside of the "flansmod" package.Intended usage in Content Packs/Users of the mod
Nothing changed here.
Compatibility
More Stability and Better Compatibility with other mods by taking more use cases with projectiles into account.