Program: 170014
Project: 170014
Buggy source:
@Override public void onUpdate(){
  if (this.mountedPlayer != null) {
    if (this.mountedPlayer.rotationPitch > 30)     this.mountedPlayer.rotationPitch=30;
    if (this.mountedPlayer.rotationPitch < -45)     this.mountedPlayer.rotationPitch=-45;
    this.wantedRotationPitch=this.mountedPlayer.rotationPitch;
    this.wantedRotationYaw=this.mountedPlayer.rotationYaw;
    this.currentRotationPitch=this.wantedRotationPitch * 0.0175f;
    this.currentRotationYaw=this.wantedRotationYaw * 0.0175f;
  }
 else   if (this.entityFake != null) {
    this.entityFake.setDead();
    this.entityFake=null;
  }
  if (this.getPlatform() != null) {
    if (this.redstonePowerOn && this.canActivateWeapon() && this.gunChargingTicks == 0) {
      this.onWeaponActivated();
    }
    if (this.gunChargingTicks > 0) {
      this.gunChargingTicks++;
      if (this.gunChargingTicks >= 70) {
        while (this.explosionDepth > 0) {
          MovingObjectPosition objectMouseOver=this.rayTrace(2000);
          if (objectMouseOver != null) {
            if (!ZhuYaoGangShao.isProtected(this.worldObj,new Vector3(objectMouseOver),ZhuYaoGangShao.FLAG_RAILGUN) && objectMouseOver.typeOfHit == EnumMovingObjectType.TILE) {
              if (this.isAntimatter) {
                int radius=50;
                AxisAlignedBB bounds=AxisAlignedBB.getBoundingBox(objectMouseOver.blockX - radius,objectMouseOver.blockY - radius,objectMouseOver.blockZ - radius,objectMouseOver.blockX + radius,objectMouseOver.blockY + radius,objectMouseOver.blockZ + radius);
                List<Entity> missilesNearby=worldObj.getEntitiesWithinAABB(Entity.class,bounds);
                for (                Entity entity : missilesNearby) {
                  if (entity instanceof IExplosive) {
                    entity.setDead();
                  }
                }
              }
              if (this.worldObj.getBlockId(objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ) != Block.bedrock.blockID) {
                this.worldObj.setBlock(objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ,0,0,2);
              }
              this.worldObj.newExplosion(this.mountedPlayer,objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ,explosionSize,true,true);
            }
          }
          this.explosionDepth--;
        }
        if (!this.worldObj.isRemote) {
          PacketManager.sendPacketToClients(PacketManager.getPacket(ZhuYaoGangShao.CHANNEL,this,3),this.worldObj,new Vector3(this),50);
        }
        this.gunChargingTicks=0;
      }
    }
    if (!this.worldObj.isRemote) {
      if (this.ticks % 600 == 0) {
        this.worldObj.markBlockForUpdate(this.xCoord,this.yCoord,this.zCoord);
      }
    }
 else     if (this.endTicks > 0) {
      Vector3 muzzilePosition=this.getMuzzle();
      this.worldObj.spawnParticle("String_Node_Str",muzzilePosition.x,muzzilePosition.y,muzzilePosition.z,0,0,0);
      this.worldObj.spawnParticle("String_Node_Str",muzzilePosition.x,muzzilePosition.y,muzzilePosition.z,0,0,0);
      MovingObjectPosition objectMouseOver=this.rayTrace(2000);
      if (objectMouseOver != null) {
        this.drawParticleStreamTo(Vector3.add(new Vector3(objectMouseOver),0.5));
      }
      this.endTicks--;
    }
  }
}

Fixed version (ground truth):
@Override public void onUpdate(){
  if (this.mountedPlayer != null) {
    if (this.mountedPlayer.rotationPitch > 30)     this.mountedPlayer.rotationPitch=30;
    if (this.mountedPlayer.rotationPitch < -45)     this.mountedPlayer.rotationPitch=-45;
    this.wantedRotationPitch=this.mountedPlayer.rotationPitch;
    this.wantedRotationYaw=this.mountedPlayer.rotationYaw;
    this.currentRotationPitch=this.wantedRotationPitch * 0.0175f;
    this.currentRotationYaw=this.wantedRotationYaw * 0.0175f;
    System.out.println("String_Node_Str" + this.worldObj.isRemote);
  }
 else   if (this.entityFake != null) {
    this.entityFake.setDead();
    this.entityFake=null;
  }
  if (this.getPlatform() != null) {
    if (this.redstonePowerOn && this.canActivateWeapon() && this.gunChargingTicks == 0) {
      this.onWeaponActivated();
    }
    if (this.gunChargingTicks > 0) {
      this.gunChargingTicks++;
      if (this.gunChargingTicks >= 70) {
        while (this.explosionDepth > 0) {
          MovingObjectPosition objectMouseOver=this.rayTrace(2000);
          if (objectMouseOver != null) {
            if (!ZhuYaoGangShao.isProtected(this.worldObj,new Vector3(objectMouseOver),ZhuYaoGangShao.FLAG_RAILGUN) && objectMouseOver.typeOfHit == EnumMovingObjectType.TILE) {
              if (this.isAntimatter) {
                int radius=50;
                AxisAlignedBB bounds=AxisAlignedBB.getBoundingBox(objectMouseOver.blockX - radius,objectMouseOver.blockY - radius,objectMouseOver.blockZ - radius,objectMouseOver.blockX + radius,objectMouseOver.blockY + radius,objectMouseOver.blockZ + radius);
                List<Entity> missilesNearby=worldObj.getEntitiesWithinAABB(Entity.class,bounds);
                for (                Entity entity : missilesNearby) {
                  if (entity instanceof IExplosive) {
                    entity.setDead();
                  }
                }
              }
              if (this.worldObj.getBlockId(objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ) != Block.bedrock.blockID) {
                this.worldObj.setBlock(objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ,0,0,2);
              }
              this.worldObj.newExplosion(this.mountedPlayer,objectMouseOver.blockX,objectMouseOver.blockY,objectMouseOver.blockZ,explosionSize,true,true);
            }
          }
          this.explosionDepth--;
        }
        if (!this.worldObj.isRemote) {
          PacketManager.sendPacketToClients(PacketManager.getPacket(ZhuYaoGangShao.CHANNEL,this,3),this.worldObj,new Vector3(this),50);
        }
        this.gunChargingTicks=0;
      }
    }
    if (!this.worldObj.isRemote) {
      if (this.ticks % 600 == 0) {
        this.worldObj.markBlockForUpdate(this.xCoord,this.yCoord,this.zCoord);
      }
    }
 else     if (this.endTicks > 0) {
      Vector3 muzzilePosition=this.getMuzzle();
      this.worldObj.spawnParticle("String_Node_Str",muzzilePosition.x,muzzilePosition.y,muzzilePosition.z,0,0,0);
      this.worldObj.spawnParticle("String_Node_Str",muzzilePosition.x,muzzilePosition.y,muzzilePosition.z,0,0,0);
      MovingObjectPosition objectMouseOver=this.rayTrace(2000);
      if (objectMouseOver != null) {
        this.drawParticleStreamTo(Vector3.add(new Vector3(objectMouseOver),0.5));
      }
      this.endTicks--;
    }
  }
}