Program: 81895
Project: 81895
Buggy source:
@SideOnly(Side.CLIENT) public void tickClient(){
  Minecraft mc=Minecraft.getMinecraft();
  World world=manager.getWorld();
  WindManager windMan=manager.getWindManager();
  if (particleBehavior == null) {
    particleBehavior=new ParticleBehaviorSandstorm(pos);
  }
  double distanceToCenter=pos.distanceTo(new Vec3(mc.thePlayer.posX,mc.thePlayer.posY,mc.thePlayer.posZ));
  double distanceToFront=distanceToCenter - size;
  boolean isInside=distanceToFront < 0;
  double circ=Math.PI * size;
  double distBetweenParticles=3;
  double degRate=360D / (circ / distBetweenParticles);
  if (mc.theWorld.getTotalWorldTime() % 40 == 0) {
  }
  Random rand=mc.theWorld.rand;
  this.height=this.size / 4;
  int heightLayers=Math.max(1,this.height / (int)distBetweenParticles);
  if ((mc.theWorld.getTotalWorldTime()) % 10 == 0) {
  }
  double distFromSpawn=this.posSpawn.distanceTo(this.pos);
  double xVec=this.posSpawn.xCoord - this.pos.xCoord;
  double zVec=this.posSpawn.zCoord - this.pos.zCoord;
  double directionAngle=Math.atan2(zVec,xVec);
  double directionAngleDeg=Math.toDegrees(directionAngle);
  int spawnedThisTick=0;
  float sandstormScale=getSandstormScale();
  double sandstormParticleRateDust=ConfigParticle.Sandstorm_Particle_Dust_effect_rate;
  if (size > 0) {
    for (int heightLayer=0; heightLayer < heightLayers && spawnedThisTick < 500; heightLayer++) {
      double i=directionAngleDeg + (rand.nextDouble() * 180D);
      if ((mc.theWorld.getTotalWorldTime()) % 2 == 0) {
        if (rand.nextDouble() >= sandstormParticleRateDust)         continue;
        double sizeSub=heightLayer * 2D;
        double sizeDyn=size - sizeSub;
        double inwardsAdj=rand.nextDouble() * 5D;
        double sizeRand=(sizeDyn + -inwardsAdj);
        double x=pos.xCoord + (-Math.sin(Math.toRadians(i)) * (sizeRand));
        double z=pos.zCoord + (Math.cos(Math.toRadians(i)) * (sizeRand));
        double y=pos.yCoord + (heightLayer * distBetweenParticles * 2);
        TextureAtlasSprite sprite=ParticleRegistry.cloud256;
        ParticleSandstorm part=new ParticleSandstorm(mc.theWorld,x,y,z,0,0,0,sprite);
        particleBehavior.initParticle(part);
        part.angleToStorm=i;
        part.distAdj=sizeRand;
        part.heightLayer=heightLayer;
        part.lockPosition=true;
        part.setFacePlayer(false);
        part.isTransparent=true;
        part.rotationYaw=(float)i + rand.nextInt(20) - 10;
        part.rotationPitch=0;
        part.setMaxAge(300);
        part.setGravity(0.09F);
        part.setAlphaF(1F);
        float brightnessMulti=1F - (rand.nextFloat() * 0.5F);
        part.setRBGColorF(0.65F * brightnessMulti,0.6F * brightnessMulti,0.3F * brightnessMulti);
        part.setScale(100);
        part.setKillOnCollide(true);
        particleBehavior.particles.add(part);
        part.spawnAsWeatherEffect();
        spawnedThisTick++;
      }
    }
  }
  if (spawnedThisTick > 0) {
    spawnedThisTick=0;
  }
  if ((mc.theWorld.getTotalWorldTime()) % 20 == 0) {
  }
  double spawnAngle=Math.atan2((double)this.sizePeak,distFromSpawn);
  spawnAngle*=1.2D;
  double spawnDistInc=10;
  double extraDistSpawnIntoWall=sizePeak / 2D;
  if ((mc.theWorld.getTotalWorldTime()) % 3 == 0) {
    for (double spawnDistTick=0; spawnDistTick < distFromSpawn + (extraDistSpawnIntoWall) && spawnedThisTick < 500; spawnDistTick+=spawnDistInc) {
      if (rand.nextDouble() >= sandstormScale)       continue;
      if (rand.nextDouble() >= sandstormParticleRateDust)       continue;
      double randAngle=directionAngle + (Math.PI / 2D) - (spawnAngle) + (rand.nextDouble() * spawnAngle * 2D);
      double randHeight=(spawnDistTick / distFromSpawn) * height * 1.2D* rand.nextDouble();
      double x=posSpawn.xCoord + (-Math.sin(randAngle) * (spawnDistTick));
      double z=posSpawn.zCoord + (Math.cos(randAngle) * (spawnDistTick));
      x+=(rand.nextDouble() - rand.nextDouble()) * 30D;
      z+=(rand.nextDouble() - rand.nextDouble()) * 30D;
      int yy=WeatherUtilBlock.getPrecipitationHeightSafe(world,new BlockPos(x,0,z)).getY();
      double y=yy + 2 + randHeight;
      TextureAtlasSprite sprite=ParticleRegistry.cloud256;
      ParticleSandstorm part=new ParticleSandstorm(mc.theWorld,x,y,z,0,0,0,sprite);
      particleBehavior.initParticle(part);
      part.setFacePlayer(false);
      part.isTransparent=true;
      part.rotationYaw=(float)rand.nextInt(360);
      part.rotationPitch=(float)rand.nextInt(360);
      part.setMaxAge(100);
      part.setGravity(0.09F);
      part.setAlphaF(1F);
      float brightnessMulti=1F - (rand.nextFloat() * 0.5F);
      part.setRBGColorF(0.65F * brightnessMulti,0.6F * brightnessMulti,0.3F * brightnessMulti);
      part.setScale(100);
      part.setKillOnCollide(true);
      part.windWeight=1F;
      particleBehavior.particles.add(part);
      part.spawnAsWeatherEffect();
      spawnedThisTick++;
    }
  }
  if (spawnedThisTick > 0) {
  }
  float angle=windMan.getWindAngleForClouds();
  float speedWind=windMan.getWindSpeedForClouds();
  double vecX=-Math.sin(Math.toRadians(angle));
  double vecZ=Math.cos(Math.toRadians(angle));
  double speed=0.8D;
  particleBehavior.coordSource=pos;
  particleBehavior.tickUpdateList();
  for (int i=0; i < particleBehavior.particles.size(); i++) {
    ParticleSandstorm particle=(ParticleSandstorm)particleBehavior.particles.get(i);
    if (particle.lockPosition) {
      if (size > 0) {
        double x=pos.xCoord + (-Math.sin(Math.toRadians(particle.angleToStorm)) * (particle.distAdj));
        double z=pos.zCoord + (Math.cos(Math.toRadians(particle.angleToStorm)) * (particle.distAdj));
        double y=pos.yCoord + (particle.heightLayer * distBetweenParticles);
        moveToPosition(particle,x,y,z,0.01D);
      }
 else {
        particle.setMotionX((vecX * speedWind * 0.3F));
        particle.setMotionZ((vecZ * speedWind * 0.3F));
      }
    }
 else {
      particle.setMotionX((vecX * speed));
      particle.setMotionZ((vecZ * speed));
    }
  }
}

Fixed version (ground truth):
@SideOnly(Side.CLIENT) public void tickClient(){
  Minecraft mc=Minecraft.getMinecraft();
  World world=manager.getWorld();
  WindManager windMan=manager.getWindManager();
  if (particleBehavior == null) {
    particleBehavior=new ParticleBehaviorSandstorm(pos);
  }
  double distanceToCenter=pos.distanceTo(new Vec3(mc.thePlayer.posX,mc.thePlayer.posY,mc.thePlayer.posZ));
  double distanceToFront=distanceToCenter - size;
  boolean isInside=distanceToFront < 0;
  double circ=Math.PI * size;
  double distBetweenParticles=3;
  double degRate=360D / (circ / distBetweenParticles);
  if (mc.theWorld.getTotalWorldTime() % 40 == 0) {
  }
  Random rand=mc.theWorld.rand;
  this.height=this.size / 4;
  int heightLayers=Math.max(1,this.height / (int)distBetweenParticles);
  if ((mc.theWorld.getTotalWorldTime()) % 10 == 0) {
  }
  double distFromSpawn=this.posSpawn.distanceTo(this.pos);
  double xVec=this.posSpawn.xCoord - this.pos.xCoord;
  double zVec=this.posSpawn.zCoord - this.pos.zCoord;
  double directionAngle=Math.atan2(zVec,xVec);
  double directionAngleDeg=Math.toDegrees(directionAngle);
  int spawnedThisTick=0;
  float sandstormScale=getSandstormScale();
  double sandstormParticleRateDust=ConfigParticle.Sandstorm_Particle_Dust_effect_rate;
  if (size > 0) {
    for (int heightLayer=0; heightLayer < heightLayers && spawnedThisTick < 500; heightLayer++) {
      double i=directionAngleDeg + (rand.nextDouble() * 180D);
      if ((mc.theWorld.getTotalWorldTime()) % 2 == 0) {
        if (rand.nextDouble() >= sandstormParticleRateDust)         continue;
        double sizeSub=heightLayer * 2D;
        double sizeDyn=size - sizeSub;
        double inwardsAdj=rand.nextDouble() * 5D;
        double sizeRand=(sizeDyn + -inwardsAdj);
        double x=pos.xCoord + (-Math.sin(Math.toRadians(i)) * (sizeRand));
        double z=pos.zCoord + (Math.cos(Math.toRadians(i)) * (sizeRand));
        double y=pos.yCoord + (heightLayer * distBetweenParticles * 2);
        TextureAtlasSprite sprite=ParticleRegistry.cloud256;
        if (WeatherUtil.isAprilFoolsDay()) {
          sprite=ParticleRegistry.chicken;
        }
        ParticleSandstorm part=new ParticleSandstorm(mc.theWorld,x,y,z,0,0,0,sprite);
        particleBehavior.initParticle(part);
        part.angleToStorm=i;
        part.distAdj=sizeRand;
        part.heightLayer=heightLayer;
        part.lockPosition=true;
        part.setFacePlayer(false);
        part.isTransparent=true;
        part.rotationYaw=(float)i + rand.nextInt(20) - 10;
        part.rotationPitch=0;
        part.setMaxAge(300);
        part.setGravity(0.09F);
        part.setAlphaF(1F);
        float brightnessMulti=1F - (rand.nextFloat() * 0.5F);
        part.setRBGColorF(0.65F * brightnessMulti,0.6F * brightnessMulti,0.3F * brightnessMulti);
        part.setScale(100);
        part.setKillOnCollide(true);
        particleBehavior.particles.add(part);
        part.spawnAsWeatherEffect();
        spawnedThisTick++;
      }
    }
  }
  if (spawnedThisTick > 0) {
    spawnedThisTick=0;
  }
  if ((mc.theWorld.getTotalWorldTime()) % 20 == 0) {
  }
  double spawnAngle=Math.atan2((double)this.sizePeak,distFromSpawn);
  spawnAngle*=1.2D;
  double spawnDistInc=10;
  double extraDistSpawnIntoWall=sizePeak / 2D;
  if ((mc.theWorld.getTotalWorldTime()) % 3 == 0) {
    for (double spawnDistTick=0; spawnDistTick < distFromSpawn + (extraDistSpawnIntoWall) && spawnedThisTick < 500; spawnDistTick+=spawnDistInc) {
      if (rand.nextDouble() >= sandstormScale)       continue;
      if (rand.nextDouble() >= sandstormParticleRateDust)       continue;
      double randAngle=directionAngle + (Math.PI / 2D) - (spawnAngle) + (rand.nextDouble() * spawnAngle * 2D);
      double randHeight=(spawnDistTick / distFromSpawn) * height * 1.2D* rand.nextDouble();
      double x=posSpawn.xCoord + (-Math.sin(randAngle) * (spawnDistTick));
      double z=posSpawn.zCoord + (Math.cos(randAngle) * (spawnDistTick));
      x+=(rand.nextDouble() - rand.nextDouble()) * 30D;
      z+=(rand.nextDouble() - rand.nextDouble()) * 30D;
      int yy=WeatherUtilBlock.getPrecipitationHeightSafe(world,new BlockPos(x,0,z)).getY();
      double y=yy + 2 + randHeight;
      TextureAtlasSprite sprite=ParticleRegistry.cloud256;
      if (WeatherUtil.isAprilFoolsDay()) {
        sprite=ParticleRegistry.chicken;
      }
      ParticleSandstorm part=new ParticleSandstorm(mc.theWorld,x,y,z,0,0,0,sprite);
      particleBehavior.initParticle(part);
      part.setFacePlayer(false);
      part.isTransparent=true;
      part.rotationYaw=(float)rand.nextInt(360);
      part.rotationPitch=(float)rand.nextInt(360);
      part.setMaxAge(100);
      part.setGravity(0.09F);
      part.setAlphaF(1F);
      float brightnessMulti=1F - (rand.nextFloat() * 0.5F);
      part.setRBGColorF(0.65F * brightnessMulti,0.6F * brightnessMulti,0.3F * brightnessMulti);
      part.setScale(100);
      part.setKillOnCollide(true);
      part.windWeight=1F;
      particleBehavior.particles.add(part);
      part.spawnAsWeatherEffect();
      spawnedThisTick++;
    }
  }
  if (spawnedThisTick > 0) {
  }
  float angle=windMan.getWindAngleForClouds();
  float speedWind=windMan.getWindSpeedForClouds();
  double vecX=-Math.sin(Math.toRadians(angle));
  double vecZ=Math.cos(Math.toRadians(angle));
  double speed=0.8D;
  particleBehavior.coordSource=pos;
  particleBehavior.tickUpdateList();
  for (int i=0; i < particleBehavior.particles.size(); i++) {
    ParticleSandstorm particle=(ParticleSandstorm)particleBehavior.particles.get(i);
    if (particle.lockPosition) {
      if (size > 0) {
        double x=pos.xCoord + (-Math.sin(Math.toRadians(particle.angleToStorm)) * (particle.distAdj));
        double z=pos.zCoord + (Math.cos(Math.toRadians(particle.angleToStorm)) * (particle.distAdj));
        double y=pos.yCoord + (particle.heightLayer * distBetweenParticles);
        moveToPosition(particle,x,y,z,0.01D);
      }
 else {
        particle.setMotionX((vecX * speedWind * 0.3F));
        particle.setMotionZ((vecZ * speedWind * 0.3F));
      }
    }
 else {
      particle.setMotionX((vecX * speed));
      particle.setMotionZ((vecZ * speed));
    }
  }
}