Fix most non rendering issues

This commit is contained in:
Vincent Lee committed 2020-01-09 21:49:02 -06:00
1 parent bafd2bfa6d
commit 24e777cab5
88 files changed
+397 -454

No files matched your search

@@ -120,7 +120,7 @@ public class EntityBabylonWeapon extends EntityThrowableCopy {
setChargeTicks(chargeTime + 1);
if(world.rand.nextInt(20) == 0)
world.playSound(null, posX, posY, posZ, ModSounds.babylonSpawn, SoundCategory.PLAYERS, 0.1F, 1F + world.rand.nextFloat() * 3F);
world.playSound(null, getX(), getY(), getZ(), ModSounds.babylonSpawn, SoundCategory.PLAYERS, 0.1F, 1F + world.rand.nextFloat() * 3F);
} else {
if(liveTime < delay) {
setMotion(Vec3d.ZERO);
@@ -138,12 +138,12 @@ public class EntityBabylonWeapon extends EntityThrowableCopy {
Vector3 motionVec = playerLook.subtract(thisVec).normalize().multiply(2);
mot = motionVec.toVec3D();
world.playSound(null, posX, posY, posZ, ModSounds.babylonAttack, SoundCategory.PLAYERS, 2F, 0.1F + world.rand.nextFloat() * 3F);
world.playSound(null, getX(), getY(), getZ(), ModSounds.babylonAttack, SoundCategory.PLAYERS, 2F, 0.1F + world.rand.nextFloat() * 3F);
}
setLiveTicks(liveTime + 1);
if(!world.isRemote) {
AxisAlignedBB axis = new AxisAlignedBB(posX, posY, posZ, lastTickPosX, lastTickPosY, lastTickPosZ).grow(2);
AxisAlignedBB axis = new AxisAlignedBB(getX(), getY(), getZ(), lastTickPosX, lastTickPosY, lastTickPosZ).grow(2);
List<LivingEntity> entities = world.getEntitiesWithinAABB(LivingEntity.class, axis);
for(LivingEntity living : entities) {
if(living == thrower)
@@ -166,7 +166,7 @@ public class EntityBabylonWeapon extends EntityThrowableCopy {
if(liveTime > delay) {
WispParticleData data = WispParticleData.wisp(0.3F, 1F, 1F, 0F, 1);
world.addParticle(data, posX, posY, posZ, 0, -0F, 0);
world.addParticle(data, getX(), getY(), getZ(), 0, -0F, 0);
}
if(liveTime > 200 + delay)
@@ -177,7 +177,7 @@ public class EntityBabylonWeapon extends EntityThrowableCopy {
protected void onImpact(RayTraceResult pos) {
LivingEntity thrower = getThrower();
if(pos.getType() != RayTraceResult.Type.ENTITY || ((EntityRayTraceResult) pos).getEntity() != thrower) {
world.createExplosion(this, posX, posY, posZ, 3F, Explosion.Mode.NONE);
world.createExplosion(this, getX(), getY(), getZ(), 3F, Explosion.Mode.NONE);
remove();
}
}