mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-25 14:34:36 +00:00
Safety guards for blockstates, remove all useless casts
This commit is contained in:
1 parent
e58eb1b345
commit
20b5743221
45 files changed
+93
-67
No files matched your search
@@ -209,7 +209,7 @@ public abstract class EntityThrowableCopy extends Entity implements IProjectile
|
||||
|
||||
for (int j = 0; j < list.size(); ++j)
|
||||
{
|
||||
Entity entity1 = (Entity)list.get(j);
|
||||
Entity entity1 = list.get(j);
|
||||
|
||||
if (entity1.canBeCollidedWith() && (entity1 != entitylivingbase || this.ticksInAir >= 5))
|
||||
{
|
||||
@@ -318,7 +318,7 @@ public abstract class EntityThrowableCopy extends Entity implements IProjectile
|
||||
tagCompound.setShort("xTile", (short)this.xTile);
|
||||
tagCompound.setShort("yTile", (short)this.yTile);
|
||||
tagCompound.setShort("zTile", (short)this.zTile);
|
||||
ResourceLocation resourcelocation = (ResourceLocation)Block.blockRegistry.getNameForObject(this.inTile);
|
||||
ResourceLocation resourcelocation = Block.blockRegistry.getNameForObject(this.inTile);
|
||||
tagCompound.setString("inTile", resourcelocation == null ? "" : resourcelocation.toString());
|
||||
tagCompound.setByte("shake", (byte)this.throwableShake);
|
||||
tagCompound.setByte("inGround", (byte)(this.inGround ? 1 : 0));
|
||||
|
||||
Reference in new issue
Block a user