nus-yam/ex-repair huggingface dataset:
Program: 81785
Project: 81785
Buggy source:
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogDensity(FogDensity event){
  float fogDensity=0;
  int delay=5000;
  long time=System.currentTimeMillis() % delay;
  fogDensity=(float)time / (float)delay;
  boolean test=false;
  if (test) {
    event.setCanceled(true);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    GlStateManager.setFogStart(0F);
    GlStateManager.setFogEnd(400F);
    event.setDensity(fogDensity);
    event.setDensity(0.5F);
  }
  boolean test2=false;
  if (test2) {
    GlStateManager.setFogStart(0F);
    GlStateManager.setFogEnd(7F);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    event.setDensity(1F);
    event.setCanceled(true);
  }
}

Fixed version (ground truth):
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogDensity(FogDensity event){
  if (ConfigMisc.Client_PotatoPC_Mode)   return;
  float fogDensity=0;
  int delay=5000;
  long time=System.currentTimeMillis() % delay;
  fogDensity=(float)time / (float)delay;
  boolean test=false;
  if (test) {
    event.setCanceled(true);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    GlStateManager.setFogStart(0F);
    GlStateManager.setFogEnd(400F);
    event.setDensity(fogDensity);
    event.setDensity(0.5F);
  }
  boolean test2=false;
  if (test2) {
    GlStateManager.setFogStart(0F);
    GlStateManager.setFogEnd(7F);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    event.setDensity(1F);
    event.setCanceled(true);
  }
}
Program: 81786
Project: 81786
Buggy source:
@SubscribeEvent @SideOnly(Side.CLIENT) public void worldRender(RenderWorldLastEvent event){
  ClientTickHandler.checkClientWeather();
  ClientTickHandler.weatherManager.tickRender(event.getPartialTicks());
  SceneEnhancer.renderWorldLast(event);
  FoliageRenderer.radialRange=ConfigFoliage.foliageShaderRange;
}

Fixed version (ground truth):
@SubscribeEvent @SideOnly(Side.CLIENT) public void worldRender(RenderWorldLastEvent event){
  if (ConfigMisc.Client_PotatoPC_Mode)   return;
  ClientTickHandler.checkClientWeather();
  ClientTickHandler.weatherManager.tickRender(event.getPartialTicks());
  SceneEnhancer.renderWorldLast(event);
  FoliageRenderer.radialRange=ConfigFoliage.foliageShaderRange;
}
Program: 81787
Project: 81787
Buggy source:
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogRender(RenderFogEvent event){
  if (SceneEnhancer.isFogOverridding()) {
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    if (event.getFogMode() == -1) {
      GlStateManager.setFogStart(SceneEnhancer.stormFogStartClouds);
      GlStateManager.setFogEnd(SceneEnhancer.stormFogEndClouds);
    }
 else {
      GlStateManager.setFogStart(SceneEnhancer.stormFogStart);
      GlStateManager.setFogEnd(SceneEnhancer.stormFogEnd);
    }
  }
}

Fixed version (ground truth):
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogRender(RenderFogEvent event){
  if (ConfigMisc.Client_PotatoPC_Mode)   return;
  if (SceneEnhancer.isFogOverridding()) {
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
    if (event.getFogMode() == -1) {
      GlStateManager.setFogStart(SceneEnhancer.stormFogStartClouds);
      GlStateManager.setFogEnd(SceneEnhancer.stormFogEndClouds);
    }
 else {
      GlStateManager.setFogStart(SceneEnhancer.stormFogStart);
      GlStateManager.setFogEnd(SceneEnhancer.stormFogEnd);
    }
  }
}
Program: 81788
Project: 81788
Buggy source:
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogColors(FogColors event){
  if (SceneEnhancer.isFogOverridding()) {
    SceneEnhancer.stormFogRedOrig=event.getRed();
    SceneEnhancer.stormFogGreenOrig=event.getGreen();
    SceneEnhancer.stormFogBlueOrig=event.getBlue();
    event.setRed(SceneEnhancer.stormFogRed);
    event.setGreen(SceneEnhancer.stormFogGreen);
    event.setBlue(SceneEnhancer.stormFogBlue);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
  }
}

Fixed version (ground truth):
@SubscribeEvent @SideOnly(Side.CLIENT) public void onFogColors(FogColors event){
  if (ConfigMisc.Client_PotatoPC_Mode)   return;
  if (SceneEnhancer.isFogOverridding()) {
    SceneEnhancer.stormFogRedOrig=event.getRed();
    SceneEnhancer.stormFogGreenOrig=event.getGreen();
    SceneEnhancer.stormFogBlueOrig=event.getBlue();
    event.setRed(SceneEnhancer.stormFogRed);
    event.setGreen(SceneEnhancer.stormFogGreen);
    event.setBlue(SceneEnhancer.stormFogBlue);
    GlStateManager.setFog(GlStateManager.FogMode.LINEAR);
  }
}
Program: 81789
Project: 81789
Buggy source:
public void tickClient(){
  if (!WeatherUtil.isPaused()) {
    tryParticleSpawning();
    tickRainRates();
    tickParticlePrecipitation();
    trySoundPlaying();
    Minecraft mc=FMLClientHandler.instance().getClient();
    if (mc.world != null && lastWorldDetected != mc.world) {
      lastWorldDetected=mc.world;
      reset();
    }
    tryWind(mc.world);
    tickSandstorm();
    if (particleBehavior == null) {
      particleBehavior=new ParticleBehaviorSandstorm(null);
    }
    particleBehavior.tickUpdateList();
    if (ConfigCoroUtil.foliageShaders && EventHandler.queryUseOfShaders()) {
      if (!FoliageEnhancerShader.useThread) {
        if (mc.world.getTotalWorldTime() % 40 == 0) {
          FoliageEnhancerShader.tickClientThreaded();
        }
      }
      if (mc.world.getTotalWorldTime() % 5 == 0) {
        FoliageEnhancerShader.tickClientCloseToPlayer();
      }
    }
  }
}

Fixed version (ground truth):
public void tickClient(){
  if (!WeatherUtil.isPaused() && !ConfigMisc.Client_PotatoPC_Mode) {
    tryParticleSpawning();
    tickRainRates();
    tickParticlePrecipitation();
    trySoundPlaying();
    Minecraft mc=FMLClientHandler.instance().getClient();
    if (mc.world != null && lastWorldDetected != mc.world) {
      lastWorldDetected=mc.world;
      reset();
    }
    tryWind(mc.world);
    tickSandstorm();
    if (particleBehavior == null) {
      particleBehavior=new ParticleBehaviorSandstorm(null);
    }
    particleBehavior.tickUpdateList();
    if (ConfigCoroUtil.foliageShaders && EventHandler.queryUseOfShaders()) {
      if (!FoliageEnhancerShader.useThread) {
        if (mc.world.getTotalWorldTime() % 40 == 0) {
          FoliageEnhancerShader.tickClientThreaded();
        }
      }
      if (mc.world.getTotalWorldTime() % 5 == 0) {
        FoliageEnhancerShader.tickClientCloseToPlayer();
      }
    }
  }
}
Program: 81790
Project: 81790
Buggy source:
public static void renderTick(TickEvent.RenderTickEvent event){
  if (event.phase == TickEvent.Phase.START) {
    Minecraft mc=FMLClientHandler.instance().getClient();
    EntityPlayer entP=mc.player;
    if (entP != null) {
      float curRainStr=SceneEnhancer.getRainStrengthAndControlVisuals(entP,true);
      curRainStr=Math.abs(curRainStr);
      mc.world.setRainStrength(curRainStr);
    }
  }
}

Fixed version (ground truth):
public static void renderTick(TickEvent.RenderTickEvent event){
  if (ConfigMisc.Client_PotatoPC_Mode)   return;
  if (event.phase == TickEvent.Phase.START) {
    Minecraft mc=FMLClientHandler.instance().getClient();
    EntityPlayer entP=mc.player;
    if (entP != null) {
      float curRainStr=SceneEnhancer.getRainStrengthAndControlVisuals(entP,true);
      curRainStr=Math.abs(curRainStr);
      mc.world.setRainStrength(curRainStr);
    }
  }
}
Program: 81791
Project: 81791
Buggy source:
@Override public void run(){
  if (useThread) {
    while (true) {
      try {
        if (ConfigCoroUtil.foliageShaders && RotatingParticleManager.useShaders) {
          boolean gotLock=tickClientThreaded();
          if (gotLock) {
            Thread.sleep(ConfigFoliage.Thread_Foliage_Process_Delay);
          }
 else {
            Thread.sleep(20);
          }
        }
 else {
          Thread.sleep(5000);
        }
      }
 catch (      Throwable throwable) {
        throwable.printStackTrace();
      }
    }
  }
}

Fixed version (ground truth):
@Override public void run(){
  if (useThread) {
    while (true) {
      try {
        if (ConfigCoroUtil.foliageShaders && RotatingParticleManager.useShaders && !ConfigMisc.Client_PotatoPC_Mode) {
          boolean gotLock=tickClientThreaded();
          if (gotLock) {
            Thread.sleep(ConfigFoliage.Thread_Foliage_Process_Delay);
          }
 else {
            Thread.sleep(20);
          }
        }
 else {
          Thread.sleep(5000);
        }
      }
 catch (      Throwable throwable) {
        throwable.printStackTrace();
      }
    }
  }
}
Program: 81794
Project: 81794
Buggy source:
public ClientTickHandler(){
  if (sceneEnhancer == null) {
    sceneEnhancer=new SceneEnhancer();
    (new Thread(sceneEnhancer,"String_Node_Str")).start();
  }
  if (foliageEnhancer == null) {
    foliageEnhancer=new FoliageEnhancerShader();
    (new Thread(foliageEnhancer,"String_Node_Str")).start();
  }
}

Fixed version (ground truth):
public ClientTickHandler(){
  if (sceneEnhancer == null) {
    sceneEnhancer=new SceneEnhancer();
    (new Thread(sceneEnhancer,"String_Node_Str")).start();
  }
  if (foliageEnhancer == null) {
    foliageEnhancer=new FoliageEnhancerShader();
    (new Thread(foliageEnhancer,"String_Node_Str")).start();
  }
  clientConfigData=new ClientConfigData();
}
Program: 81796
Project: 81796
Buggy source:
@SubscribeEvent public void onPacketFromServer(FMLNetworkEvent.ClientCustomPacketEvent event){
  try {
    final NBTTagCompound nbt=PacketHelper.readNBTTagCompound(event.getPacket().payload());
    final String packetCommand=nbt.getString("String_Node_Str");
    final String command=nbt.getString("String_Node_Str");
    Minecraft.getMinecraft().addScheduledTask(() -> {
      if (packetCommand.equals("String_Node_Str")) {
        ClientTickHandler.checkClientWeather();
        ClientTickHandler.weatherManager.nbtSyncFromServer(nbt);
      }
 else       if (packetCommand.equals("String_Node_Str")) {
        Weather.dbg("String_Node_Str" + command);
        if (command.equals("String_Node_Str")) {
          WeatherUtilConfig.nbtReceiveServerDataForCache(nbt);
        }
      }
 else       if (packetCommand.equals("String_Node_Str")) {
        if (command.equals("String_Node_Str")) {
          ItemPocketSand.particulateFromServer(nbt.getString("String_Node_Str"));
        }
      }
    }
);
  }
 catch (  Exception ex) {
    ex.printStackTrace();
  }
}

Fixed version (ground truth):
@SubscribeEvent public void onPacketFromServer(FMLNetworkEvent.ClientCustomPacketEvent event){
  try {
    final NBTTagCompound nbt=PacketHelper.readNBTTagCompound(event.getPacket().payload());
    final String packetCommand=nbt.getString("String_Node_Str");
    final String command=nbt.getString("String_Node_Str");
    Minecraft.getMinecraft().addScheduledTask(() -> {
      if (packetCommand.equals("String_Node_Str")) {
        ClientTickHandler.checkClientWeather();
        ClientTickHandler.weatherManager.nbtSyncFromServer(nbt);
      }
 else       if (packetCommand.equals("String_Node_Str")) {
        Weather.dbg("String_Node_Str" + command);
        if (command.equals("String_Node_Str")) {
          WeatherUtilConfig.nbtReceiveServerDataForCache(nbt);
        }
      }
 else       if (packetCommand.equals("String_Node_Str")) {
        if (command.equals("String_Node_Str")) {
          ItemPocketSand.particulateFromServer(nbt.getString("String_Node_Str"));
        }
      }
 else       if (packetCommand.equals("String_Node_Str")) {
        if (command.equals("String_Node_Str")) {
          ClientTickHandler.clientConfigData.readNBT(nbt);
        }
      }
    }
);
  }
 catch (  Exception ex) {
    ex.printStackTrace();
  }
}
Program: 81803
Project: 81803
Buggy source:
@Mod.EventHandler public void preInit(FMLPreInitializationEvent event){
  eventChannel.register(new EventHandlerPacket());
  MinecraftForge.EVENT_BUS.register(new EventHandlerFML());
  MinecraftForge.EVENT_BUS.register(new EventHandlerForge());
  ConfigMod.addConfigFile(event,addConfig(new ConfigMisc()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigWind()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigSand()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigSnow()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigStorm()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigTornado()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigParticle()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigFoliage()));
  WeatherUtilConfig.nbtLoadDataAll();
  proxy.preInit();
}

Fixed version (ground truth):
@Mod.EventHandler public void preInit(FMLPreInitializationEvent event){
  eventChannel.register(new EventHandlerPacket());
  MinecraftForge.EVENT_BUS.register(new EventHandlerFML());
  MinecraftForge.EVENT_BUS.register(new EventHandlerForge());
  configMisc=new ConfigMisc();
  ConfigMod.addConfigFile(event,addConfig(configMisc));
  ConfigMod.addConfigFile(event,addConfig(new ConfigWind()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigSand()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigSnow()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigStorm()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigTornado()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigParticle()));
  ConfigMod.addConfigFile(event,addConfig(new ConfigFoliage()));
  WeatherUtilConfig.nbtLoadDataAll();
  proxy.preInit();
}
Program: 81809
Project: 81809
Buggy source:
public boolean canSnowAtBody(int par1,int par2,int par3){
  World world=manager.getWorld();
  Biome biomegenbase=world.getBiome(new BlockPos(par1,0,par3));
  BlockPos pos=new BlockPos(par1,par2,par3);
  if (biomegenbase == null)   return false;
  float f=biomegenbase.getFloatTemperature(new BlockPos(par1,par2,par3));
  if ((canSnowFromCloudTemperature && levelTemperature > 0) || (!canSnowFromCloudTemperature && biomegenbase.getFloatTemperature(new BlockPos(par1,par2,par3)) > 0.15F)) {
    return false;
  }
 else {
    if (par2 >= 0 && par2 < 256 && world.getLightFor(EnumSkyBlock.BLOCK,new BlockPos(par1,par2,par3)) < 10) {
      IBlockState iblockstate1=world.getBlockState(pos);
      if ((iblockstate1.getBlock().isAir(iblockstate1,world,pos) || iblockstate1.getBlock() == Blocks.SNOW_LAYER) && Blocks.SNOW_LAYER.canPlaceBlockAt(world,pos)) {
        return true;
      }
    }
    return false;
  }
}

Fixed version (ground truth):
public boolean canSnowAtBody(int par1,int par2,int par3){
  World world=manager.getWorld();
  Biome biomegenbase=world.getBiome(new BlockPos(par1,0,par3));
  BlockPos pos=new BlockPos(par1,par2,par3);
  if (biomegenbase == null)   return false;
  float temperature=CoroUtilCompatibility.getAdjustedTemperature(world,biomegenbase,pos);
  if ((canSnowFromCloudTemperature && levelTemperature > 0) || (!canSnowFromCloudTemperature && temperature > 0.15F)) {
    return false;
  }
 else {
    if (par2 >= 0 && par2 < 256 && world.getLightFor(EnumSkyBlock.BLOCK,pos) < 10) {
      IBlockState iblockstate1=world.getBlockState(pos);
      if ((iblockstate1.getBlock().isAir(iblockstate1,world,pos) || iblockstate1.getBlock() == Blocks.SNOW_LAYER) && Blocks.SNOW_LAYER.canPlaceBlockAt(world,pos)) {
        return true;
      }
    }
    return false;
  }
}
Program: 81811
Project: 81811
Buggy source:
public void initFirstTime(){
  super.initFirstTime();
  Biome bgb=manager.getWorld().getBiome(new BlockPos(MathHelper.floor(pos.xCoord),0,MathHelper.floor(pos.zCoord)));
  float temp=1;
  if (bgb != null) {
    temp=bgb.getFloatTemperature(new BlockPos(MathHelper.floor(pos.xCoord),MathHelper.floor(pos.yCoord),MathHelper.floor(pos.zCoord)));
  }
  if (naturallySpawned) {
    levelTemperature=getTemperatureMCToWeatherSys(temp);
  }
  levelWindMomentum=0;
}

Fixed version (ground truth):
public void initFirstTime(){
  super.initFirstTime();
  Biome bgb=manager.getWorld().getBiome(new BlockPos(MathHelper.floor(pos.xCoord),0,MathHelper.floor(pos.zCoord)));
  float temp=1;
  if (bgb != null) {
    temp=CoroUtilCompatibility.getAdjustedTemperature(manager.getWorld(),bgb,new BlockPos(MathHelper.floor(pos.xCoord),MathHelper.floor(pos.yCoord),MathHelper.floor(pos.zCoord)));
  }
  if (naturallySpawned) {
    levelTemperature=getTemperatureMCToWeatherSys(temp);
  }
  levelWindMomentum=0;
}
Program: 81813
Project: 81813
Buggy source:
/** 
 * Called from shaders listener
 */
public static void shadersInit(){
  FoliageEnhancerShader.setupReplacers();
  for (  FoliageReplacerBase replacer : listFoliageReplacers) {
    for (    TextureAtlasSprite sprite : replacer.sprites) {
      MeshBufferManagerFoliage.setupMeshIfMissing(sprite);
    }
  }
}

Fixed version (ground truth):
/** 
 * Called from shaders listener
 */
public static void shadersInit(){
  FoliageEnhancerShader.setupReplacers();
  CULog.log("String_Node_Str");
  for (  FoliageReplacerBase replacer : listFoliageReplacers) {
    for (    TextureAtlasSprite sprite : replacer.sprites) {
      MeshBufferManagerFoliage.setupMeshIfMissing(sprite);
    }
  }
}
Program: 81816
Project: 81816
Buggy source:
public void tickWeatherCoverage(){
  World world=this.getWorld();
  if (world != null) {
    if (!ConfigMisc.overcastMode) {
      if (ConfigMisc.lockServerWeatherMode != -1) {
        world.getWorldInfo().setRaining(ConfigMisc.lockServerWeatherMode == 1);
        world.getWorldInfo().setThundering(ConfigMisc.lockServerWeatherMode == 1);
      }
    }
    if (ConfigStorm.preventServerThunderstorms) {
      world.getWorldInfo().setThundering(false);
    }
    if (world.getTotalWorldTime() % 400 == 0) {
      isVanillaRainActiveOnServer=getWorld().isRaining();
      syncWeatherVanilla();
    }
    if (world.getTotalWorldTime() % 400 == 0) {
    }
    if (world.getTotalWorldTime() % 200 == 0) {
      Random rand=new Random();
      cloudIntensity+=(float)((rand.nextDouble() * ConfigMisc.Cloud_Coverage_Random_Change_Amount) - (rand.nextDouble() * ConfigMisc.Cloud_Coverage_Random_Change_Amount));
      if (cloudIntensity < ConfigMisc.Cloud_Coverage_Min_Percent / 100F) {
        cloudIntensity=(float)ConfigMisc.Cloud_Coverage_Min_Percent / 100F;
      }
 else       if (cloudIntensity > ConfigMisc.Cloud_Coverage_Max_Percent / 100F) {
        cloudIntensity=(float)ConfigMisc.Cloud_Coverage_Max_Percent / 100F;
      }
      if (world.getTotalWorldTime() % 2000 == 0) {
      }
    }
  }
}

Fixed version (ground truth):
public void tickWeatherCoverage(){
  World world=this.getWorld();
  if (world != null) {
    if (!ConfigMisc.overcastMode) {
      if (ConfigMisc.lockServerWeatherMode != -1) {
        world.getWorldInfo().setRaining(ConfigMisc.lockServerWeatherMode == 1);
        world.getWorldInfo().setThundering(ConfigMisc.lockServerWeatherMode == 1);
      }
    }
    boolean test=world.getWorldInfo().isRaining();
    if (ConfigStorm.preventServerThunderstorms) {
      world.getWorldInfo().setThundering(false);
    }
    if (world.getTotalWorldTime() % 400 == 0) {
      isVanillaRainActiveOnServer=getWorld().isRaining();
      syncWeatherVanilla();
    }
    if (world.getTotalWorldTime() % 400 == 0) {
    }
    if (world.getTotalWorldTime() % 200 == 0) {
      Random rand=new Random();
      cloudIntensity+=(float)((rand.nextDouble() * ConfigMisc.Cloud_Coverage_Random_Change_Amount) - (rand.nextDouble() * ConfigMisc.Cloud_Coverage_Random_Change_Amount));
      if (cloudIntensity < ConfigMisc.Cloud_Coverage_Min_Percent / 100F) {
        cloudIntensity=(float)ConfigMisc.Cloud_Coverage_Min_Percent / 100F;
      }
 else       if (cloudIntensity > ConfigMisc.Cloud_Coverage_Max_Percent / 100F) {
        cloudIntensity=(float)ConfigMisc.Cloud_Coverage_Max_Percent / 100F;
      }
      if (world.getTotalWorldTime() % 2000 == 0) {
      }
    }
  }
}
Program: 81822
Project: 81822
Buggy source:
public static void modelBakeEvent(ModelBakeEvent event){
  Map<ModelResourceLocation,IModel> stateModels=ReflectionHelper.getPrivateValue(ModelLoader.class,event.getModelLoader(),"String_Node_Str");
  IBakedModel blank=event.getModelRegistry().getObject(new ModelResourceLocation("String_Node_Str","String_Node_Str"));
  for (  ModelResourceLocation res : event.getModelRegistry().getKeys()) {
    IBakedModel bakedModel=event.getModelRegistry().getObject(res);
    IModel model=stateModels.get(res);
    Set<ResourceLocation> textures=Sets.newHashSet(model.getTextures());
    escape:     if (!res.getVariant().equals("String_Node_Str")) {
      for (      FoliageReplacerBase replacer : listFoliageReplacers) {
        for (        TextureAtlasSprite sprite : replacer.sprites) {
          for (          ResourceLocation res2 : textures) {
            if (res2.toString().equals(sprite.getIconName())) {
              if (!res.toString().contains("String_Node_Str")) {
                System.out.println("String_Node_Str" + res + "String_Node_Str");
                event.getModelRegistry().putObject(res,blank);
                break escape;
              }
            }
          }
        }
      }
    }
  }
}

Fixed version (ground truth):
public static void modelBakeEvent(ModelBakeEvent event){
  boolean replaceVanillaModels=true;
  if (replaceVanillaModels) {
    Map<ModelResourceLocation,IModel> stateModels=ReflectionHelper.getPrivateValue(ModelLoader.class,event.getModelLoader(),"String_Node_Str");
    IBakedModel blank=event.getModelRegistry().getObject(new ModelResourceLocation("String_Node_Str","String_Node_Str"));
    for (    ModelResourceLocation res : event.getModelRegistry().getKeys()) {
      IBakedModel bakedModel=event.getModelRegistry().getObject(res);
      IModel model=stateModels.get(res);
      Set<ResourceLocation> textures=Sets.newHashSet(model.getTextures());
      escape:       if (!res.getVariant().equals("String_Node_Str")) {
        for (        FoliageReplacerBase replacer : listFoliageReplacers) {
          for (          TextureAtlasSprite sprite : replacer.sprites) {
            for (            ResourceLocation res2 : textures) {
              if (res2.toString().equals(sprite.getIconName())) {
                if (!res.toString().contains("String_Node_Str")) {
                  System.out.println("String_Node_Str" + res + "String_Node_Str");
                  event.getModelRegistry().putObject(res,blank);
                  break escape;
                }
              }
            }
          }
        }
      }
    }
  }
}
Program: 81826
Project: 81826
Buggy source:
@Override public boolean validFoliageSpot(World world,BlockPos pos){
  if (world.getBlockState(pos).getMaterial() == baseMaterial) {
    if (stateSensitive) {
      IBlockState stateScan=world.getBlockState(pos.up());
      if (stateScan.getBlock() == state.getBlock()) {
        boolean fail=false;
        for (        Map.Entry<IProperty,Comparable> entrySet : lookupPropertiesToComparable.entrySet()) {
          if (stateScan.getValue(entrySet.getKey()) != entrySet.getValue()) {
            fail=true;
            break;
          }
        }
        if (fail) {
          return false;
        }
        return true;
      }
 else {
        return false;
      }
    }
 else {
      return world.getBlockState(pos.up()).getBlock() == state.getBlock();
    }
  }
 else {
    return false;
  }
}

Fixed version (ground truth):
@Override public boolean validFoliageSpot(World world,BlockPos pos){
  if (baseMaterial == null || world.getBlockState(pos).getMaterial() == baseMaterial) {
    if (stateSensitive) {
      IBlockState stateScan=world.getBlockState(pos.up());
      if (stateScan.getBlock() == state.getBlock()) {
        boolean fail=false;
        for (        Map.Entry<IProperty,Comparable> entrySet : lookupPropertiesToComparable.entrySet()) {
          if (stateScan.getValue(entrySet.getKey()) != entrySet.getValue()) {
            fail=true;
            break;
          }
        }
        if (fail) {
          return false;
        }
        return true;
      }
 else {
        return false;
      }
    }
 else {
      return world.getBlockState(pos.up()).getBlock() == state.getBlock();
    }
  }
 else {
    return false;
  }
}
Program: 81827
Project: 81827
Buggy source:
@Override public void addForPos(World world,BlockPos pos){
  int height=expectedHeight;
  if (height == -1) {
    Block block=state.getBlock();
    height=0;
    while (block == state.getBlock()) {
      height++;
      block=world.getBlockState(pos.up(height + 1)).getBlock();
    }
  }
  FoliageEnhancerShader.addForPos(this,height,pos,randomizeCoord,biomeColorize);
}

Fixed version (ground truth):
@Override public void addForPos(World world,BlockPos pos){
  int height=expectedHeight;
  if (height == -1) {
    Block block=state.getBlock();
    height=0;
    while (block == state.getBlock()) {
      height++;
      block=world.getBlockState(pos.up(height + 1)).getBlock();
    }
    height++;
  }
  FoliageEnhancerShader.addForPos(this,height,pos,randomizeCoord,biomeColorize);
}
Program: 81828
Project: 81828
Buggy source:
public static void init(){
  listFoliageReplacers.add(new FoliageReplacer1TallPlant(Blocks.TALLGRASS.getDefaultState(),ParticleRegistry.tallgrass));
}

Fixed version (ground truth):
public static void init(){
  listFoliageReplacers.add(new FoliageReplacer1TallPlant(Blocks.TALLGRASS.getDefaultState(),ParticleRegistry.tallgrass));
  listFoliageReplacers.add(new FoliageReplacerMultiTallPlant(Blocks.DOUBLE_PLANT.getDefaultState(),ParticleRegistry.double_plant_bottom));
}
Program: 81830
Project: 81830
Buggy source:
public FoliageReplacerMultiTallPlant(IBlockState state){
  this.state=state;
}

Fixed version (ground truth):
public FoliageReplacerMultiTallPlant(IBlockState state,TextureAtlasSprite sprite){
  this.state=state;
  this.sprite=sprite;
}
Program: 81831
Project: 81831
Buggy source:
@Override public void addForPos(World world,BlockPos pos){
}

Fixed version (ground truth):
@Override public void addForPos(World world,BlockPos pos){
  ExtendedRenderer.foliageRenderer.addForPos(this,sprite,pos);
}
Program: 81833
Project: 81833
Buggy source:
public static void updateVBO2Threaded(){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  float partialTicks=1F;
  Foliage.interpPosXThread=entityIn.posX;
  Foliage.interpPosYThread=entityIn.posY;
  Foliage.interpPosZThread=entityIn.posZ;
  MeshBufferManagerFoliage.setupMeshIfMissing(ParticleRegistry.tallgrass);
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(ParticleRegistry.tallgrass);
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  List<Foliage> listFoliage : ExtendedRenderer.foliageRenderer.lookupPosToFoliage.values()) {
    for (    Foliage foliage : listFoliage) {
      foliage.updateQuaternion(entityIn);
      foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
    }
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
}

Fixed version (ground truth):
public static void updateVBO2Threaded(){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  float partialTicks=1F;
  Foliage.interpPosXThread=entityIn.posX;
  Foliage.interpPosYThread=entityIn.posY;
  Foliage.interpPosZThread=entityIn.posZ;
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(ParticleRegistry.tallgrass);
  if (mesh == null)   return;
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  List<Foliage> listFoliage : ExtendedRenderer.foliageRenderer.lookupPosToFoliage.values()) {
    for (    Foliage foliage : listFoliage) {
      foliage.updateQuaternion(entityIn);
      foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
    }
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
}
Program: 81835
Project: 81835
Buggy source:
@Override protected void renderRainSnow(float par1){
  boolean overrideOn=ConfigMisc.Misc_proxyRenderOverrideEnabled;
  if (!overrideOn) {
    super.renderRainSnow(par1);
    return;
  }
 else {
    if (!ConfigParticle.Particle_RainSnow) {
      super.renderRainSnow(par1);
    }
  }
}

Fixed version (ground truth):
@Override protected void renderRainSnow(float par1){
  boolean overrideOn=ConfigMisc.Misc_proxyRenderOverrideEnabled;
  EventHandler.hookRenderShaders(par1);
  if (!overrideOn) {
    super.renderRainSnow(par1);
    return;
  }
 else {
    if (!ConfigParticle.Particle_RainSnow) {
      super.renderRainSnow(par1);
    }
  }
}
Program: 81838
Project: 81838
Buggy source:
public static boolean validFoliageSpot(World world,BlockPos pos){
  return world.getBlockState(pos).getMaterial() == Material.GRASS;
}

Fixed version (ground truth):
public static boolean validFoliageSpot(World world,BlockPos pos){
  return world.getBlockState(pos).getMaterial() != Material.WATER && world.getBlockState(pos.up()).getMaterial() == Material.WATER;
}
Program: 81839
Project: 81839
Buggy source:
public static void updateVBO2Threaded(TextureAtlasSprite sprite){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  float partialTicks=1F;
  Foliage.interpPosXThread=entityIn.posX;
  Foliage.interpPosYThread=entityIn.posY;
  Foliage.interpPosZThread=entityIn.posZ;
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(sprite);
  if (mesh == null)   return;
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  Foliage foliage : ExtendedRenderer.foliageRenderer.getFoliageForSprite(sprite)) {
    foliage.updateQuaternion(entityIn);
    foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
}

Fixed version (ground truth):
public static void updateVBO2Threaded(TextureAtlasSprite sprite){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  float partialTicks=1F;
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(sprite);
  if (mesh == null)   return;
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  Foliage foliage : ExtendedRenderer.foliageRenderer.getFoliageForSprite(sprite)) {
    foliage.updateQuaternion(entityIn);
    foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
}
Program: 81841
Project: 81841
Buggy source:
public static void updateVBO2Threaded(){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  ExtendedRenderer.foliageRenderer.processQueue();
  float partialTicks=1F;
  Foliage.interpPosXThread=entityIn.posX;
  Foliage.interpPosYThread=entityIn.posY;
  Foliage.interpPosZThread=entityIn.posZ;
  MeshBufferManagerFoliage.setupMeshIfMissing(ParticleRegistry.tallgrass);
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(ParticleRegistry.tallgrass);
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  List<Foliage> listFoliage : ExtendedRenderer.foliageRenderer.lookupPosToFoliage.values()) {
    for (    Foliage foliage : listFoliage) {
      foliage.updateQuaternion(entityIn);
      foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
    }
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
  FoliageRenderer.vbo2BufferPos=mesh.curBufferPosVBO2;
}

Fixed version (ground truth):
public static void updateVBO2Threaded(){
  Minecraft mc=Minecraft.getMinecraft();
  Entity entityIn=mc.getRenderViewEntity();
  ExtendedRenderer.foliageRenderer.processQueue();
  float partialTicks=1F;
  Foliage.interpPosXThread=entityIn.posX;
  Foliage.interpPosYThread=entityIn.posY;
  Foliage.interpPosZThread=entityIn.posZ;
  MeshBufferManagerFoliage.setupMeshIfMissing(ParticleRegistry.tallgrass);
  InstancedMeshFoliage mesh=MeshBufferManagerFoliage.getMesh(ParticleRegistry.tallgrass);
  mesh.curBufferPosVBO2=0;
  mesh.instanceDataBufferVBO2.clear();
  for (  List<Foliage> listFoliage : ExtendedRenderer.foliageRenderer.lookupPosToFoliage.values()) {
    for (    Foliage foliage : listFoliage) {
      foliage.updateQuaternion(entityIn);
      foliage.renderForShaderVBO2(mesh,ExtendedRenderer.foliageRenderer.transformation,null,entityIn,partialTicks);
    }
  }
  mesh.instanceDataBufferVBO2.limit(mesh.curBufferPosVBO2 * mesh.INSTANCE_SIZE_FLOATS_SELDOM);
}
Program: 81842
Project: 81842
Buggy source:
public void addItemModel(Item item,int meta,ModelResourceLocation location){
  Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item,meta,location);
}

Fixed version (ground truth):
public void addItemModel(Item item,int meta,ModelResourceLocation location){
  ModelLoader.setCustomModelResourceLocation(item,meta,location);
}
Program: 81843
Project: 81843
Buggy source:
public void onRenderScreenTick(){
  Minecraft mc=FMLClientHandler.instance().getClient();
  if (mc.currentScreen instanceof GuiIngameMenu) {
    ScaledResolution scaledresolution=new ScaledResolution(mc);
    int i=scaledresolution.getScaledWidth();
    int j=scaledresolution.getScaledHeight();
    int k=Mouse.getX() * i / mc.displayWidth;
    int l=j - Mouse.getY() * j / mc.displayHeight - 1;
    configButton=new GuiButton(0,(i / 2) - 100,0,200,20,"String_Node_Str");
    configButton.drawButton(mc,k,l);
    if (k >= configButton.xPosition && l >= configButton.yPosition && k < configButton.xPosition + 200 && l < configButton.yPosition + 20) {
      if (Mouse.isButtonDown(0)) {
        mc.displayGuiScreen(new GuiEZConfig());
      }
    }
  }
}

Fixed version (ground truth):
public void onRenderScreenTick(){
  Minecraft mc=FMLClientHandler.instance().getClient();
  if (mc.currentScreen instanceof GuiIngameMenu) {
    ScaledResolution scaledresolution=new ScaledResolution(mc);
    int i=scaledresolution.getScaledWidth();
    int j=scaledresolution.getScaledHeight();
    int k=Mouse.getX() * i / mc.displayWidth;
    int l=j - Mouse.getY() * j / mc.displayHeight - 1;
    configButton=new GuiButton(0,(i / 2) - 100,0,200,20,"String_Node_Str");
    configButton.drawButton(mc,k,l,1F);
    if (k >= configButton.x && l >= configButton.y && k < configButton.x + 200 && l < configButton.y + 20) {
      if (Mouse.isButtonDown(0)) {
        mc.displayGuiScreen(new GuiEZConfig());
      }
    }
  }
}
Program: 81846
Project: 81846
Buggy source:
public void addItem(RegistryEvent.Register<Item> event,Item item,String name){
  item.setUnlocalizedName(Weather.modID + "String_Node_Str" + name);
  item.setRegistryName(name);
  item.setCreativeTab(tab);
  if (event != null) {
    event.getRegistry().register(item);
  }
 else {
    GameRegistry.register(item);
  }
}

Fixed version (ground truth):
public void addItem(RegistryEvent.Register<Item> event,Item item,String name){
  item.setUnlocalizedName(Weather.modID + "String_Node_Str" + name);
  item.setRegistryName(name);
  item.setCreativeTab(tab);
  if (event != null) {
    event.getRegistry().register(item);
  }
 else {
  }
}
Program: 81847
Project: 81847
Buggy source:
@SubscribeEvent public void registerBlocks(RegistryEvent.Register<Block> event){
  addBlock(event,blockTSensor=(new BlockTSensor()),tornado_sensor);
  addBlock(event,blockTSiren=(new BlockTSiren()),TileEntityTSiren.class,tornado_siren);
  addBlock(event,blockWindVane=(new BlockWindVane()),TileEntityWindVane.class,wind_vane);
  addBlock(event,blockWeatherForecast=(new BlockWeatherForecast()),TileEntityWeatherForecast.class,weather_forecast);
  addBlock(event,blockWeatherMachine=(new BlockWeatherMachine()),TileEntityWeatherMachine.class,weather_machine);
  addBlock(event,blockWeatherDeflector=(new BlockWeatherDeflector()),TileEntityWeatherDeflector.class,weather_deflector);
  addBlock(event,blockAnemometer=(new BlockAnemometer()),TileEntityAnemometer.class,anemometer);
  addBlock(event,blockSandLayer=(new BlockSandLayer()),sand_layer,false);
}

Fixed version (ground truth):
@SubscribeEvent public static void registerBlocks(RegistryEvent.Register<Block> event){
  Weather.proxy.addBlock(event,blockTSensor=(new BlockTSensor()),tornado_sensor);
  Weather.proxy.addBlock(event,blockTSiren=(new BlockTSiren()),TileEntityTSiren.class,tornado_siren);
  Weather.proxy.addBlock(event,blockWindVane=(new BlockWindVane()),TileEntityWindVane.class,wind_vane);
  Weather.proxy.addBlock(event,blockWeatherForecast=(new BlockWeatherForecast()),TileEntityWeatherForecast.class,weather_forecast);
  Weather.proxy.addBlock(event,blockWeatherMachine=(new BlockWeatherMachine()),TileEntityWeatherMachine.class,weather_machine);
  Weather.proxy.addBlock(event,blockWeatherDeflector=(new BlockWeatherDeflector()),TileEntityWeatherDeflector.class,weather_deflector);
  Weather.proxy.addBlock(event,blockAnemometer=(new BlockAnemometer()),TileEntityAnemometer.class,anemometer);
  Weather.proxy.addBlock(event,blockSandLayer=(new BlockSandLayer()),sand_layer,false);
}
Program: 81848
Project: 81848
Buggy source:
public void addBlock(RegistryEvent.Register<Block> event,Block parBlock,String unlocalizedName,boolean creativeTab){
  parBlock.setUnlocalizedName(Weather.modID + "String_Node_Str" + unlocalizedName);
  parBlock.setRegistryName(unlocalizedName);
  if (creativeTab) {
    parBlock.setCreativeTab(tab);
  }
 else {
    parBlock.setCreativeTab(null);
  }
  if (event != null) {
    event.getRegistry().register(parBlock);
  }
 else {
    GameRegistry.register(parBlock);
  }
  GameRegistry.register(new ItemBlock(parBlock),parBlock.getRegistryName());
}

Fixed version (ground truth):
public void addBlock(RegistryEvent.Register<Block> event,Block parBlock,String unlocalizedName,boolean creativeTab){
  parBlock.setUnlocalizedName(Weather.modID + "String_Node_Str" + unlocalizedName);
  parBlock.setRegistryName(unlocalizedName);
  if (creativeTab) {
    parBlock.setCreativeTab(tab);
  }
 else {
    parBlock.setCreativeTab(null);
  }
  if (event != null) {
    event.getRegistry().register(parBlock);
  }
 else {
  }
}
Program: 81849
Project: 81849
Buggy source:
@SubscribeEvent public void registerItems(RegistryEvent.Register<Item> event){
  addItem(event,itemSandLayer=new ItemSandLayer(blockSandLayer),sand_layer_placeable);
  addItem(event,itemWeatherRecipe=new ItemWeatherRecipe(),weather_item);
  addItem(event,itemPocketSand=new ItemPocketSand(),pocket_sand);
}

Fixed version (ground truth):
@SubscribeEvent public static void registerItems(RegistryEvent.Register<Item> event){
  Weather.proxy.addItem(event,itemSandLayer=new ItemSandLayer(blockSandLayer),sand_layer_placeable);
  Weather.proxy.addItem(event,itemWeatherRecipe=new ItemWeatherRecipe(),weather_item);
  Weather.proxy.addItem(event,itemPocketSand=new ItemPocketSand(),pocket_sand);
  event.getRegistry().register(new ItemBlock(blockTSensor).setRegistryName(blockTSensor.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockTSiren).setRegistryName(blockTSiren.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWindVane).setRegistryName(blockWindVane.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherForecast).setRegistryName(blockWeatherForecast.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherMachine).setRegistryName(blockWeatherMachine.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherDeflector).setRegistryName(blockWeatherDeflector.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockAnemometer).setRegistryName(blockAnemometer.getRegistryName()));
}
Program: 81853
Project: 81853
Buggy source:
public static void register(String soundPath){
  ResourceLocation resLoc=new ResourceLocation(Weather.modID,soundPath);
  SoundEvent event=new SoundEvent(resLoc);
  GameRegistry.register(event,resLoc);
  if (lookupStringToEvent.containsKey(soundPath)) {
    System.out.println("String_Node_Str" + soundPath);
  }
  lookupStringToEvent.put(soundPath,event);
}

Fixed version (ground truth):
public static void register(String soundPath){
  ResourceLocation resLoc=new ResourceLocation(Weather.modID,soundPath);
  SoundEvent event=new SoundEvent(resLoc).setRegistryName(resLoc);
  ForgeRegistries.SOUND_EVENTS.register(event);
  if (lookupStringToEvent.containsKey(soundPath)) {
    System.out.println("String_Node_Str" + soundPath);
  }
  lookupStringToEvent.put(soundPath,event);
}
Program: 81854
Project: 81854
Buggy source:
public static void tickTestSandstormParticles(){
  Minecraft mc=Minecraft.getMinecraft();
  if (vecWOP == null) {
    particleBehaviorFog=new ParticleBehaviorFogGround(new Vec3(mc.player.posX,mc.player.posY,mc.player.posZ));
    vecWOP=new Vec3d(mc.player.posX,mc.player.posY,mc.player.posZ);
  }
  for (int i=0; i < 0; i++) {
    ParticleTexFX part=new ParticleTexFX(mc.world,vecWOP.xCoord,vecWOP.yCoord,vecWOP.zCoord,0,0,0,ParticleRegistry.cloud256);
    particleBehaviorFog.initParticle(part);
    part.setFacePlayer(false);
    part.spawnAsWeatherEffect();
  }
  boolean derp=false;
  if (derp) {
    IBlockState state=mc.world.getBlockState(new BlockPos(mc.player.posX,mc.player.getEntityBoundingBox().minY - 1,mc.player.posZ));
    int id=Block.getStateId(state);
    id=12520;
    double speed=0.2D;
    Random rand=mc.world.rand;
    mc.world.spawnParticle(EnumParticleTypes.BLOCK_DUST,mc.player.posX,mc.player.posY,mc.player.posZ,(rand.nextDouble() - rand.nextDouble()) * speed,(rand.nextDouble()) * speed * 2D,(rand.nextDouble() - rand.nextDouble()) * speed,id);
  }
}

Fixed version (ground truth):
public static void tickTestSandstormParticles(){
  Minecraft mc=Minecraft.getMinecraft();
  if (vecWOP == null) {
    particleBehaviorFog=new ParticleBehaviorFogGround(new Vec3(mc.player.posX,mc.player.posY,mc.player.posZ));
    vecWOP=new Vec3d(mc.player.posX,mc.player.posY,mc.player.posZ);
  }
  for (int i=0; i < 0; i++) {
    ParticleTexFX part=new ParticleTexFX(mc.world,vecWOP.x,vecWOP.y,vecWOP.z,0,0,0,ParticleRegistry.cloud256);
    particleBehaviorFog.initParticle(part);
    part.setFacePlayer(false);
    part.spawnAsWeatherEffect();
  }
  boolean derp=false;
  if (derp) {
    IBlockState state=mc.world.getBlockState(new BlockPos(mc.player.posX,mc.player.getEntityBoundingBox().minY - 1,mc.player.posZ));
    int id=Block.getStateId(state);
    id=12520;
    double speed=0.2D;
    Random rand=mc.world.rand;
    mc.world.spawnParticle(EnumParticleTypes.BLOCK_DUST,mc.player.posX,mc.player.posY,mc.player.posZ,(rand.nextDouble() - rand.nextDouble()) * speed,(rand.nextDouble()) * speed * 2D,(rand.nextDouble() - rand.nextDouble()) * speed,id);
  }
}
Program: 81855
Project: 81855
Buggy source:
@Override public void addBlock(RegistryEvent.Register<Block> event,Block parBlock,String name,boolean creativeTab){
  super.addBlock(event,parBlock,name,creativeTab);
  addItemModel(Item.getItemFromBlock(parBlock),0,new ModelResourceLocation(Weather.modID + "String_Node_Str" + name,"String_Node_Str"));
}

Fixed version (ground truth):
@Override public void addBlock(RegistryEvent.Register<Block> event,Block parBlock,String name,boolean creativeTab){
  super.addBlock(event,parBlock,name,creativeTab);
}
Program: 81856
Project: 81856
Buggy source:
@SubscribeEvent public static void registerItems(RegistryEvent.Register<Item> event){
  Weather.proxy.addItem(event,itemSandLayer=new ItemSandLayer(blockSandLayer),sand_layer_placeable);
  Weather.proxy.addItem(event,itemWeatherRecipe=new ItemWeatherRecipe(),weather_item);
  Weather.proxy.addItem(event,itemPocketSand=new ItemPocketSand(),pocket_sand);
  event.getRegistry().register(new ItemBlock(blockTSensor).setRegistryName(blockTSensor.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockTSiren).setRegistryName(blockTSiren.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWindVane).setRegistryName(blockWindVane.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherForecast).setRegistryName(blockWeatherForecast.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherMachine).setRegistryName(blockWeatherMachine.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockWeatherDeflector).setRegistryName(blockWeatherDeflector.getRegistryName()));
  event.getRegistry().register(new ItemBlock(blockAnemometer).setRegistryName(blockAnemometer.getRegistryName()));
}

Fixed version (ground truth):
@SubscribeEvent public static void registerItems(RegistryEvent.Register<Item> event){
  Weather.proxy.addItem(event,itemSandLayer=new ItemSandLayer(blockSandLayer),sand_layer_placeable);
  Weather.proxy.addItem(event,itemWeatherRecipe=new ItemWeatherRecipe(),weather_item);
  Weather.proxy.addItem(event,itemPocketSand=new ItemPocketSand(),pocket_sand);
  Weather.proxy.addItemBlock(event,new ItemBlock(blockTSensor).setRegistryName(blockTSensor.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockTSiren).setRegistryName(blockTSiren.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockWindVane).setRegistryName(blockWindVane.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockWeatherForecast).setRegistryName(blockWeatherForecast.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockWeatherMachine).setRegistryName(blockWeatherMachine.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockWeatherDeflector).setRegistryName(blockWeatherDeflector.getRegistryName()));
  Weather.proxy.addItemBlock(event,new ItemBlock(blockAnemometer).setRegistryName(blockAnemometer.getRegistryName()));
}
Program: 81858
Project: 81858
Buggy source:
public void drawTexturedModalRect(int x,int y,int textureX,int textureY,int width,int height){
  float f=0.00390625F / 2F;
  float f1=0.00390625F / 2F;
  Tessellator tessellator=Tessellator.getInstance();
  BufferBuilder worldrenderer=tessellator.getBuffer();
  worldrenderer.begin(7,DefaultVertexFormats.POSITION_TEX);
  worldrenderer.pos((double)(x + 0),(double)(y + height),(double)this.zLevel).tex((double)((float)(textureX + 0) * f),(double)((float)(textureY + height) * f1)).endVertex();
  worldrenderer.pos((double)(x + width),(double)(y + height),(double)this.zLevel).tex((double)((float)(textureX + width) * f),(double)((float)(textureY + height) * f1)).endVertex();
  worldrenderer.pos((double)(x + width),(double)(y + 0),(double)this.zLevel).tex((double)((float)(textureX + width) * f),(double)((float)(textureY + 0) * f1)).endVertex();
  worldrenderer.pos((double)(x + 0),(double)(y + 0),(double)this.zLevel).tex((double)((float)(textureX + 0) * f),(double)((float)(textureY + 0) * f1)).endVertex();
  tessellator.draw();
}

Fixed version (ground truth):
@Override public void drawTexturedModalRect(int x,int y,int textureX,int textureY,int width,int height){
  float f=0.00390625F / 2F;
  float f1=0.00390625F / 2F;
  Tessellator tessellator=Tessellator.getInstance();
  BufferBuilder worldrenderer=tessellator.getBuffer();
  worldrenderer.begin(7,DefaultVertexFormats.POSITION_TEX);
  worldrenderer.pos((double)(x + 0),(double)(y + height),(double)this.zLevel).tex((double)((float)(textureX + 0) * f),(double)((float)(textureY + height) * f1)).endVertex();
  worldrenderer.pos((double)(x + width),(double)(y + height),(double)this.zLevel).tex((double)((float)(textureX + width) * f),(double)((float)(textureY + height) * f1)).endVertex();
  worldrenderer.pos((double)(x + width),(double)(y + 0),(double)this.zLevel).tex((double)((float)(textureX + width) * f),(double)((float)(textureY + 0) * f1)).endVertex();
  worldrenderer.pos((double)(x + 0),(double)(y + 0),(double)this.zLevel).tex((double)((float)(textureX + 0) * f),(double)((float)(textureY + 0) * f1)).endVertex();
  tessellator.draw();
}
Program: 81859
Project: 81859
Buggy source:
@Override public boolean doesGuiPauseGame(){
  return false;
}

Fixed version (ground truth):
@Override public boolean doesGuiPauseGame(){
  return true;
}
Program: 81860
Project: 81860
Buggy source:
public <T extends GuiButton>T addButton(T p_189646_1_){
  buttonsLookup.put(p_189646_1_.id,p_189646_1_);
  this.buttonList.add(p_189646_1_);
  return p_189646_1_;
}

Fixed version (ground truth):
@Override public <T extends GuiButton>T addButton(T p_189646_1_){
  buttonsLookup.put(p_189646_1_.id,p_189646_1_);
  this.buttonList.add(p_189646_1_);
  return p_189646_1_;
}
Program: 81863
Project: 81863
Buggy source:
/** 
 * Fired when the mouse button is released. Equivalent of MouseListener.mouseReleased(MouseEvent e).
 */
public void mouseReleased(int par1,int par2){
}

Fixed version (ground truth):
/** 
 * Fired when the mouse button is released. Equivalent of MouseListener.mouseReleased(MouseEvent e).
 */
@Override public void mouseReleased(int par1,int par2){
}