nus-yam/ex-repair huggingface dataset:
Program: 22218
Project: 22218
Buggy source:
@Override public Multimap<String,AttributeModifier> getAttributeModifiersForExosuit(EntityEquipmentSlot armorSlot,ItemStack armorPieceStack){
  Multimap<String,AttributeModifier> map=HashMultimap.create();
  map.put(SharedMonsterAttributes.KNOCKBACK_RESISTANCE.getAttributeUnlocalizedName(),new AttributeModifier(new UUID(776437,armorSlot.getSlotIndex()),"String_Node_Str" + armorSlot.getName(),0.25D,0));
  return map;
}

Fixed version (ground truth):
@Override public Multimap<String,AttributeModifier> getAttributeModifiersForExosuit(EntityEquipmentSlot armorSlot,ItemStack armorPieceStack){
  Multimap<String,AttributeModifier> map=HashMultimap.create();
  map.put(SharedMonsterAttributes.KNOCKBACK_RESISTANCE.getName(),new AttributeModifier(new UUID(776437,armorSlot.getSlotIndex()),"String_Node_Str" + armorSlot.getName(),0.25D,0));
  return map;
}
Program: 22219
Project: 22219
Buggy source:
@Override public void onPlayerHurt(LivingHurtEvent event,EntityPlayer victim,ItemStack armorStack,EntityEquipmentSlot slot){
  EntityLivingBase entity=event.getEntityLiving();
  float amount=event.getAmount();
  if (!INVALID_SOURCES.contains(event.getSource()) && ChargableUtility.hasPower(entity,Config.zincPlateConsumption)) {
    float health=victim.getHealth();
    float maxHealth=victim.getMaxHealth();
    float halfOfMax=maxHealth / 2;
    if (amount >= halfOfMax || health <= halfOfMax) {
      ItemStack zincPlates=new ItemStack(METAL_PLATE,2,ItemMetalPlate.Types.ZINC_PLATE.getMeta());
      World world=victim.worldObj;
      ChargableUtility.drainSteam(victim.getItemStackFromSlot(EntityEquipmentSlot.CHEST),Config.zincPlateConsumption,victim);
      UtilPlates.removePlate(armorStack);
      EntityItem entityItem=new EntityItem(world,victim.posX,victim.posY,victim.posZ,zincPlates);
      world.spawnEntityInWorld(entityItem);
      victim.setHealth(health);
      victim.performHurtAnimation();
      world.playSound(victim.posX,victim.posY,victim.posZ,EsteemedInnovation.SOUND_HISS,SoundCategory.PLAYERS,2F,0.9F,false);
      event.setCanceled(true);
    }
  }
}

Fixed version (ground truth):
@Override public void onPlayerHurt(LivingHurtEvent event,EntityPlayer victim,ItemStack armorStack,EntityEquipmentSlot slot){
  EntityLivingBase entity=event.getEntityLiving();
  float amount=event.getAmount();
  if (!INVALID_SOURCES.contains(event.getSource()) && ChargableUtility.hasPower(entity,Config.zincPlateConsumption)) {
    float health=victim.getHealth();
    float maxHealth=victim.getMaxHealth();
    float halfOfMax=maxHealth / 2;
    if (amount >= halfOfMax || health <= halfOfMax) {
      ItemStack zincPlates=new ItemStack(METAL_PLATE,2,ItemMetalPlate.Types.ZINC_PLATE.getMeta());
      World world=victim.world;
      ChargableUtility.drainSteam(victim.getItemStackFromSlot(EntityEquipmentSlot.CHEST),Config.zincPlateConsumption,victim);
      UtilPlates.removePlate(armorStack);
      EntityItem entityItem=new EntityItem(world,victim.posX,victim.posY,victim.posZ,zincPlates);
      world.spawnEntity(entityItem);
      victim.setHealth(health);
      victim.performHurtAnimation();
      world.playSound(victim.posX,victim.posY,victim.posZ,EsteemedInnovation.SOUND_HISS,SoundCategory.PLAYERS,2F,0.9F,false);
      event.setCanceled(true);
    }
  }
}
Program: 22220
Project: 22220
Buggy source:
@Override @SideOnly(Side.CLIENT) public void getSubItems(Item item,CreativeTabs tabs,List<ItemStack> subItems){
  for (int i=0; i < ArmorModule.MAX_PLATE_META; i++) {
    subItems.add(ArmorModule.plateStack(i));
  }
}

Fixed version (ground truth):
@Override @SideOnly(Side.CLIENT) public void getSubItems(Item item,CreativeTabs tabs,NonNullList<ItemStack> subItems){
  for (int i=0; i < ArmorModule.MAX_PLATE_META; i++) {
    subItems.add(ArmorModule.plateStack(i));
  }
}
Program: 22221
Project: 22221
Buggy source:
@Override public ItemStack decrStackSize(ItemStack me,int var1,int var2){
  if (getStackInSlot(me,var1) != null) {
    ItemStack itemstack;
    if (getStackInSlot(me,var1).stackSize <= var2) {
      itemstack=getStackInSlot(me,var1);
      setInventorySlotContents(me,var1,null);
      hasPlates(me);
      return itemstack;
    }
 else {
      ItemStack stack2=getStackInSlot(me,var1);
      itemstack=stack2.splitStack(var2);
      setInventorySlotContents(me,var1,stack2);
      if (getStackInSlot(me,var1).stackSize == 0) {
        setInventorySlotContents(me,var1,null);
      }
      hasPlates(me);
      return itemstack;
    }
  }
 else {
    return null;
  }
}

Fixed version (ground truth):
@Override public ItemStack decrStackSize(ItemStack me,int var1,int var2){
  if (getStackInSlot(me,var1) != null) {
    ItemStack itemstack;
    if (getStackInSlot(me,var1).getCount() <= var2) {
      itemstack=getStackInSlot(me,var1);
      setInventorySlotContents(me,var1,null);
      hasPlates(me);
      return itemstack;
    }
 else {
      ItemStack stack2=getStackInSlot(me,var1);
      itemstack=stack2.splitStack(var2);
      setInventorySlotContents(me,var1,stack2);
      if (getStackInSlot(me,var1).isEmpty()) {
        setInventorySlotContents(me,var1,null);
      }
      hasPlates(me);
      return itemstack;
    }
  }
 else {
    return null;
  }
}
Program: 22222
Project: 22222
Buggy source:
@Override public boolean canPutInSlot(ItemStack me,int slotNum,ItemStack upgrade){
  if (slotNum == 0) {
    ItemStack clone=upgrade.copy();
    clone.stackSize=1;
    return UtilPlates.getPlate(clone) != null;
  }
  if (upgrade.getItem() instanceof ExosuitUpgrade) {
    ExosuitUpgrade upgradeItem=(ExosuitUpgrade)upgrade.getItem();
    ExosuitSlot upgradeSlot=upgradeItem.getSlot();
    return (upgradeSlot.getArmorPiece() == armorType && upgradeSlot.getEngineeringSlot() == slotNum) || (upgradeItem.getSlot() == ExosuitSlot.VANITY && upgradeSlot.getEngineeringSlot() == slotNum);
  }
 else   if (slotNum == ExosuitSlot.VANITY.getEngineeringSlot()) {
    int[] ids=OreDictionary.getOreIDs(upgrade);
    for (    int id : ids) {
      String str=OreDictionary.getOreName(id);
      if (str.contains("String_Node_Str")) {
        return true;
      }
    }
  }
  return false;
}

Fixed version (ground truth):
@Override public boolean canPutInSlot(ItemStack me,int slotNum,ItemStack upgrade){
  if (slotNum == 0) {
    ItemStack clone=upgrade.copy();
    clone.setCount(1);
    return UtilPlates.getPlate(clone) != null;
  }
  if (upgrade.getItem() instanceof ExosuitUpgrade) {
    ExosuitUpgrade upgradeItem=(ExosuitUpgrade)upgrade.getItem();
    ExosuitSlot upgradeSlot=upgradeItem.getSlot();
    return (upgradeSlot.getArmorPiece() == armorType && upgradeSlot.getEngineeringSlot() == slotNum) || (upgradeItem.getSlot() == ExosuitSlot.VANITY && upgradeSlot.getEngineeringSlot() == slotNum);
  }
 else   if (slotNum == ExosuitSlot.VANITY.getEngineeringSlot()) {
    int[] ids=OreDictionary.getOreIDs(upgrade);
    for (    int id : ids) {
      String str=OreDictionary.getOreName(id);
      if (str.contains("String_Node_Str")) {
        return true;
      }
    }
  }
  return false;
}
Program: 22223
Project: 22223
Buggy source:
@Override public int getArmorDisplay(EntityPlayer player,ItemStack armor,int slot){
  if (armor.hasTagCompound()) {
    if (armor.getTagCompound().hasKey("String_Node_Str")) {
      ExosuitPlate plate=UtilPlates.getPlate(armor.getTagCompound().getString("String_Node_Str"));
      return plate.getDamageReductionAmount(armorType,DamageSource.generic);
    }
  }
  return ItemArmor.ArmorMaterial.LEATHER.getDamageReductionAmount(armorType);
}

Fixed version (ground truth):
@Override public int getArmorDisplay(EntityPlayer player,ItemStack armor,int slot){
  if (armor.hasTagCompound()) {
    if (armor.getTagCompound().hasKey("String_Node_Str")) {
      ExosuitPlate plate=UtilPlates.getPlate(armor.getTagCompound().getString("String_Node_Str"));
      return plate.getDamageReductionAmount(armorType,DamageSource.GENERIC);
    }
  }
  return ItemArmor.ArmorMaterial.LEATHER.getDamageReductionAmount(armorType);
}
Program: 22225
Project: 22225
Buggy source:
@Override public ItemStack getStackInSlot(ItemStack me,int var1){
  if (me.hasTagCompound()) {
    if (me.getTagCompound().hasKey("String_Node_Str")) {
      if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(var1))) {
        return ItemStack.loadItemStackFromNBT(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(var1)));
      }
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public ItemStack getStackInSlot(ItemStack me,int var1){
  if (me.hasTagCompound()) {
    if (me.getTagCompound().hasKey("String_Node_Str")) {
      if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(var1))) {
        return new ItemStack(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(var1)));
      }
    }
  }
  return null;
}
Program: 22226
Project: 22226
Buggy source:
/** 
 * Gets whether the given armor has a tank upgrade.
 * @param me The ItemStack
 */
public boolean hasTank(ItemStack me){
  if (armorType != EntityEquipmentSlot.CHEST) {
    return false;
  }
  if (!me.hasTagCompound()) {
    return false;
  }
  if (!me.getTagCompound().hasKey("String_Node_Str")) {
    return false;
  }
  NBTTagCompound inv=me.getTagCompound().getCompoundTag("String_Node_Str");
  for (int i=1; i < 10; i++) {
    String s=Integer.toString(i);
    if (inv.hasKey(s)) {
      ItemStack stack=ItemStack.loadItemStackFromNBT(inv.getCompoundTag(s));
      if (stack != null && stack.getItem() != null && stack.getItem() instanceof ExosuitTank) {
        return true;
      }
    }
  }
  return false;
}

Fixed version (ground truth):
/** 
 * Gets whether the given armor has a tank upgrade.
 * @param me The ItemStack
 */
public boolean hasTank(ItemStack me){
  if (armorType != EntityEquipmentSlot.CHEST) {
    return false;
  }
  if (!me.hasTagCompound()) {
    return false;
  }
  if (!me.getTagCompound().hasKey("String_Node_Str")) {
    return false;
  }
  NBTTagCompound inv=me.getTagCompound().getCompoundTag("String_Node_Str");
  for (int i=1; i < 10; i++) {
    String s=Integer.toString(i);
    if (inv.hasKey(s)) {
      ItemStack stack=new ItemStack(inv.getCompoundTag(s));
      if (stack != null && stack.getItem() != null && stack.getItem() instanceof ExosuitTank) {
        return true;
      }
    }
  }
  return false;
}
Program: 22227
Project: 22227
Buggy source:
public boolean hasPlates(ItemStack me){
  if (getStackInSlot(me,1) != null) {
    if (!me.hasTagCompound()) {
      me.setTagCompound(new NBTTagCompound());
    }
    ItemStack clone=getStackInSlot(me,1).copy();
    clone.stackSize=1;
    if (UtilPlates.getPlate(clone) != null) {
      me.getTagCompound().setString("String_Node_Str",UtilPlates.getPlate(clone).getIdentifier());
      return true;
    }
 else {
      UtilPlates.removePlate(me);
      return false;
    }
  }
 else {
    if (!me.hasTagCompound()) {
      me.setTagCompound(new NBTTagCompound());
    }
    UtilPlates.removePlate(me);
    return false;
  }
}

Fixed version (ground truth):
public boolean hasPlates(ItemStack me){
  if (getStackInSlot(me,1) != null) {
    if (!me.hasTagCompound()) {
      me.setTagCompound(new NBTTagCompound());
    }
    ItemStack clone=getStackInSlot(me,1).copy();
    clone.setCount(1);
    if (UtilPlates.getPlate(clone) != null) {
      me.getTagCompound().setString("String_Node_Str",UtilPlates.getPlate(clone).getIdentifier());
      return true;
    }
 else {
      UtilPlates.removePlate(me);
      return false;
    }
  }
 else {
    if (!me.hasTagCompound()) {
      me.setTagCompound(new NBTTagCompound());
    }
    UtilPlates.removePlate(me);
    return false;
  }
}
Program: 22228
Project: 22228
Buggy source:
@Override @Nonnull public ExosuitUpgrade[] getUpgrades(ItemStack me){
  ArrayList<ExosuitUpgrade> upgrades=new ArrayList<>();
  if (me.hasTagCompound()) {
    if (me.getTagCompound().hasKey("String_Node_Str")) {
      for (int i=2; i < 10; i++) {
        if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(i))) {
          ItemStack stack=ItemStack.loadItemStackFromNBT(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(i)));
          if (stack.getItem() instanceof ExosuitUpgrade) {
            upgrades.add((ExosuitUpgrade)stack.getItem());
          }
        }
      }
    }
  }
  return upgrades.toArray(new ExosuitUpgrade[0]);
}

Fixed version (ground truth):
@Override @Nonnull public ExosuitUpgrade[] getUpgrades(ItemStack me){
  ArrayList<ExosuitUpgrade> upgrades=new ArrayList<>();
  if (me.hasTagCompound()) {
    if (me.getTagCompound().hasKey("String_Node_Str")) {
      for (int i=2; i < 10; i++) {
        if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(i))) {
          ItemStack stack=new ItemStack(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(i)));
          if (stack.getItem() instanceof ExosuitUpgrade) {
            upgrades.add((ExosuitUpgrade)stack.getItem());
          }
        }
      }
    }
  }
  return upgrades.toArray(new ExosuitUpgrade[0]);
}
Program: 22229
Project: 22229
Buggy source:
@Override public boolean hasUpgrade(ItemStack me,Item check){
  if (me != null && check != null && me.hasTagCompound() && me.getTagCompound().hasKey("String_Node_Str")) {
    for (int i=1; i < 10; i++) {
      if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(i))) {
        ItemStack stack=ItemStack.loadItemStackFromNBT(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(i)));
        if (stack.getItem() == check) {
          return true;
        }
      }
    }
  }
  return false;
}

Fixed version (ground truth):
@Override public boolean hasUpgrade(ItemStack me,Item check){
  if (me != null && check != null && me.hasTagCompound() && me.getTagCompound().hasKey("String_Node_Str")) {
    for (int i=1; i < 10; i++) {
      if (me.getTagCompound().getCompoundTag("String_Node_Str").hasKey(Integer.toString(i))) {
        ItemStack stack=new ItemStack(me.getTagCompound().getCompoundTag("String_Node_Str").getCompoundTag(Integer.toString(i)));
        if (stack.getItem() == check) {
          return true;
        }
      }
    }
  }
  return false;
}
Program: 22230
Project: 22230
Buggy source:
private void hideCloakedPlayers(EntityLiving entity,EntityLivingBase target){
  if (target == null || !isInstalled(target)) {
    return;
  }
  IAttributeInstance iattributeinstance=entity.getEntityAttribute(SharedMonsterAttributes.FOLLOW_RANGE);
  double d0=(iattributeinstance == null ? 16.0D : iattributeinstance.getAttributeValue()) / 1.5D;
  List<Entity> list=entity.worldObj.getEntitiesWithinAABB(Entity.class,entity.getEntityBoundingBox().expand(d0,4.0D,d0));
  boolean foundPlayer=false;
  for (  Entity mob : list) {
    if (mob == target) {
      foundPlayer=true;
      break;
    }
  }
  if (!foundPlayer) {
    entity.setAttackTarget(null);
  }
}

Fixed version (ground truth):
private void hideCloakedPlayers(EntityLiving entity,EntityLivingBase target){
  if (target == null || !isInstalled(target)) {
    return;
  }
  IAttributeInstance iattributeinstance=entity.getEntityAttribute(SharedMonsterAttributes.FOLLOW_RANGE);
  double d0=(iattributeinstance == null ? 16.0D : iattributeinstance.getAttributeValue()) / 1.5D;
  List<Entity> list=entity.world.getEntitiesWithinAABB(Entity.class,entity.getEntityBoundingBox().expand(d0,4.0D,d0));
  boolean foundPlayer=false;
  for (  Entity mob : list) {
    if (mob == target) {
      foundPlayer=true;
      break;
    }
  }
  if (!foundPlayer) {
    entity.setAttackTarget(null);
  }
}
Program: 22231
Project: 22231
Buggy source:
@SideOnly(Side.CLIENT) @SubscribeEvent public void muffleSounds(PlaySoundEvent event){
  if (event.getName().contains("String_Node_Str")) {
    float x=event.getSound().getXPosF();
    float y=event.getSound().getYPosF();
    float z=event.getSound().getZPosF();
    List<EntityLivingBase> entities=Minecraft.getMinecraft().thePlayer.worldObj.getEntitiesWithinAABB(EntityLivingBase.class,new AxisAlignedBB(x - 0.5F,y - 0.5F,z - 0.5F,x + 0.5F,y + 0.5F,z + 0.5F));
    for (    EntityLivingBase entity : entities) {
      if (isInstalled(entity)) {
        event.setResultSound(null);
      }
    }
  }
}

Fixed version (ground truth):
@SideOnly(Side.CLIENT) @SubscribeEvent public void muffleSounds(PlaySoundEvent event){
  if (event.getName().contains("String_Node_Str")) {
    float x=event.getSound().getXPosF();
    float y=event.getSound().getYPosF();
    float z=event.getSound().getZPosF();
    List<EntityLivingBase> entities=Minecraft.getMinecraft().player.world.getEntitiesWithinAABB(EntityLivingBase.class,new AxisAlignedBB(x - 0.5F,y - 0.5F,z - 0.5F,x + 0.5F,y + 0.5F,z + 0.5F));
    for (    EntityLivingBase entity : entities) {
      if (isInstalled(entity)) {
        event.setResultSound(null);
      }
    }
  }
}
Program: 22233
Project: 22233
Buggy source:
@Override public void onPlayerHurt(LivingHurtEvent event,EntityPlayer victim,ItemStack armorStack,EntityEquipmentSlot slot){
  if (event.getSource() == DamageSource.fall) {
    boolean hasPower=ChargableUtility.hasPower(event.getEntityLiving(),(int)(event.getAmount() / Config.fallAssistDivisor));
    if (hasPower) {
      if (event.getAmount() <= 6.0F) {
        event.setAmount(0F);
      }
      event.setAmount(event.getAmount() / 3F);
      ChargableUtility.drainSteam(victim.getItemStackFromSlot(EntityEquipmentSlot.CHEST),(int)(event.getAmount() / Config.fallAssistDivisor),victim);
      if (event.getAmount() == 0.0F) {
        event.setResult(Event.Result.DENY);
        event.setCanceled(true);
      }
    }
  }
}

Fixed version (ground truth):
@Override public void onPlayerHurt(LivingHurtEvent event,EntityPlayer victim,ItemStack armorStack,EntityEquipmentSlot slot){
  if (event.getSource() == DamageSource.FALL) {
    boolean hasPower=ChargableUtility.hasPower(event.getEntityLiving(),(int)(event.getAmount() / Config.fallAssistDivisor));
    if (hasPower) {
      if (event.getAmount() <= 6.0F) {
        event.setAmount(0F);
      }
      event.setAmount(event.getAmount() / 3F);
      ChargableUtility.drainSteam(victim.getItemStackFromSlot(EntityEquipmentSlot.CHEST),(int)(event.getAmount() / Config.fallAssistDivisor),victim);
      if (event.getAmount() == 0.0F) {
        event.setResult(Event.Result.DENY);
        event.setCanceled(true);
      }
    }
  }
}
Program: 22234
Project: 22234
Buggy source:
/** 
 * Gets the smasher output for the provided ItemStack.
 * @param input The input ItemStack
 * @param world The current world
 * @return The output ItemStacks.
 */
@Nonnull public static List<ItemStack> getOutput(ItemStack input,World world){
  if (input == null) {
    return Collections.emptyList();
  }
  List<ItemStack> output=new ArrayList<>();
  for (  Map.Entry<ItemStack,BiFunction<ItemStack,World,List<ItemStack>>> entry : registry.entrySet()) {
    if (ItemStack.areItemStacksEqual(entry.getKey(),input)) {
      output=entry.getValue().apply(input,world);
      if (!output.isEmpty()) {
        break;
      }
    }
  }
  return output.stream().map(ItemStack::copyItemStack).collect(Collectors.toList());
}

Fixed version (ground truth):
/** 
 * Gets the smasher output for the provided ItemStack.
 * @param input The input ItemStack
 * @param world The current world
 * @return The output ItemStacks.
 */
@Nonnull public static List<ItemStack> getOutput(ItemStack input,World world){
  if (input == null) {
    return Collections.emptyList();
  }
  List<ItemStack> output=new ArrayList<>();
  for (  Map.Entry<ItemStack,BiFunction<ItemStack,World,List<ItemStack>>> entry : registry.entrySet()) {
    if (ItemStack.areItemStacksEqual(entry.getKey(),input)) {
      output=entry.getValue().apply(input,world);
      if (!output.isEmpty()) {
        break;
      }
    }
  }
  return output.stream().map(ItemStack::copy).collect(Collectors.toList());
}
Program: 22235
Project: 22235
Buggy source:
public int getTicks(ItemStack[] stacks){
  return MathHelper.floor_double((Minecraft.getMinecraft().thePlayer.ticksExisted % (stacks.length * 20D)) / 20D);
}

Fixed version (ground truth):
public int getTicks(ItemStack[] stacks){
  return MathHelper.floor((Minecraft.getMinecraft().player.ticksExisted % (stacks.length * 20D)) / 20D);
}
Program: 22237
Project: 22237
Buggy source:
@Override public void renderPage(int x,int y,FontRenderer fontRenderer,GuiJournal book,RenderItem renderer,boolean isFirstPage,int mx,int my){
  book.getMC().getTextureManager().bindTexture(craftSquareTexture);
  ((Gui)book).drawTexturedModalRect(x + 45,y + 65,0,146,97,59);
  fontRenderer.setUnicodeFlag(false);
  int ticks=getTicks(fluidItemRepresentation);
  drawItemStack(fluidItemRepresentation[ticks],x + 40 + 19+ 28,y + 65 + 14,liquidAmount > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,true);
  drawItemStack(inputItem,x + 43,y + 65 + 14,inputItem.stackSize > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,true);
  drawItemStack(resultItem,x + 40 + 90,y + 65 + 14,resultItem.stackSize > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,false);
  fontRenderer.setUnicodeFlag(true);
}

Fixed version (ground truth):
@Override public void renderPage(int x,int y,FontRenderer fontRenderer,GuiJournal book,RenderItem renderer,boolean isFirstPage,int mx,int my){
  book.getMC().getTextureManager().bindTexture(craftSquareTexture);
  ((Gui)book).drawTexturedModalRect(x + 45,y + 65,0,146,97,59);
  fontRenderer.setUnicodeFlag(false);
  int ticks=getTicks(fluidItemRepresentation);
  drawItemStack(fluidItemRepresentation[ticks],x + 40 + 19+ 28,y + 65 + 14,liquidAmount > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,true);
  drawItemStack(inputItem,x + 43,y + 65 + 14,inputItem.getCount() > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,true);
  drawItemStack(resultItem,x + 40 + 90,y + 65 + 14,resultItem.getCount() > 1 ? Integer.toString(liquidAmount) : "String_Node_Str",renderer,fontRenderer,false);
  fontRenderer.setUnicodeFlag(true);
}
Program: 22238
Project: 22238
Buggy source:
/** 
 * Registers a Crucible melting recipe for a tool.
 * @param item The input item.
 * @param liquid The output liquid.
 * @param m The amount of liquid.
 */
public static void registerMeltRecipeTool(Item item,CrucibleLiquid liquid,int m){
  for (int i=0; i < item.getMaxDamage(); i++) {
    liquidRecipes.put(Pair.of(item,i),Pair.of(liquid,MathHelper.floor_double(m * ((float)(item.getMaxDamage() - i) / (float)item.getMaxDamage()))));
  }
}

Fixed version (ground truth):
/** 
 * Registers a Crucible melting recipe for a tool.
 * @param item The input item.
 * @param liquid The output liquid.
 * @param m The amount of liquid.
 */
public static void registerMeltRecipeTool(Item item,CrucibleLiquid liquid,int m){
  for (int i=0; i < item.getMaxDamage(); i++) {
    liquidRecipes.put(Pair.of(item,i),Pair.of(liquid,MathHelper.floor(m * ((float)(item.getMaxDamage() - i) / (float)item.getMaxDamage()))));
  }
}
Program: 22239
Project: 22239
Buggy source:
@Override public void setThrowableHeading(double x,double y,double z,float velocity,float inaccuracy){
  float var9=MathHelper.sqrt_double(x * x + y * y + z * z);
  x/=(double)var9;
  y/=(double)var9;
  z/=(double)var9;
  x+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  y+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  z+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  x*=(double)velocity;
  y*=(double)velocity;
  z*=(double)velocity;
  this.motionX=x;
  this.motionY=y;
  this.motionZ=z;
  float var10=MathHelper.sqrt_double(x * x + z * z);
  this.prevRotationYaw=this.rotationYaw=(float)(Math.atan2(x,z) * 180.0D / Math.PI);
  this.prevRotationPitch=this.rotationPitch=(float)(Math.atan2(y,(double)var10) * 180.0D / Math.PI);
  this.ticksInGround=0;
}

Fixed version (ground truth):
@Override public void setThrowableHeading(double x,double y,double z,float velocity,float inaccuracy){
  float var9=MathHelper.sqrt(x * x + y * y + z * z);
  x/=(double)var9;
  y/=(double)var9;
  z/=(double)var9;
  x+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  y+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  z+=this.rand.nextGaussian() * 0.007499999832361937D * (double)inaccuracy;
  x*=(double)velocity;
  y*=(double)velocity;
  z*=(double)velocity;
  this.motionX=x;
  this.motionY=y;
  this.motionZ=z;
  float var10=MathHelper.sqrt(x * x + z * z);
  this.prevRotationYaw=this.rotationYaw=(float)(Math.atan2(x,z) * 180.0D / Math.PI);
  this.prevRotationPitch=this.rotationPitch=(float)(Math.atan2(y,(double)var10) * 180.0D / Math.PI);
  this.ticksInGround=0;
}
Program: 22240
Project: 22240
Buggy source:
@Override @SideOnly(Side.CLIENT) public void setVelocity(double x,double y,double z){
  motionX=x;
  motionY=y;
  motionZ=z;
  if (prevRotationPitch == 0.0F && prevRotationYaw == 0.0F) {
    float var7=MathHelper.sqrt_double(x * x + z * z);
    prevRotationYaw=rotationYaw=(float)(Math.atan2(x,z) * 180.0D / Math.PI);
    prevRotationPitch=rotationPitch=(float)(Math.atan2(y,(double)var7) * 180.0D / Math.PI);
    prevRotationPitch=rotationPitch;
    prevRotationYaw=rotationYaw;
    setLocationAndAngles(posX,posY,posZ,rotationYaw,rotationPitch);
    ticksInGround=0;
  }
}

Fixed version (ground truth):
@Override @SideOnly(Side.CLIENT) public void setVelocity(double x,double y,double z){
  motionX=x;
  motionY=y;
  motionZ=z;
  if (prevRotationPitch == 0.0F && prevRotationYaw == 0.0F) {
    float var7=MathHelper.sqrt(x * x + z * z);
    prevRotationYaw=rotationYaw=(float)(Math.atan2(x,z) * 180.0D / Math.PI);
    prevRotationPitch=rotationPitch=(float)(Math.atan2(y,(double)var7) * 180.0D / Math.PI);
    prevRotationPitch=rotationPitch;
    prevRotationYaw=rotationYaw;
    setLocationAndAngles(posX,posY,posZ,rotationYaw,rotationPitch);
    ticksInGround=0;
  }
}
Program: 22242
Project: 22242
Buggy source:
public EntityRocket(World world,EntityPlayer player,float par4,float size){
  super(world);
  inputParam4=par4;
  shootingEntity=player;
  explosionSize=size;
  setSize(0.25F,0.25F);
  setLocationAndAngles(player.posX,player.posY + (double)player.getEyeHeight(),player.posZ,player.rotationYaw + ((itemRand.nextFloat() - 0.5F) * par4 * 15F),player.rotationPitch + ((itemRand.nextFloat() - 0.5F) * par4 * 15F));
  setPosition(this.posX,this.posY,this.posZ);
  posX-=1.0D * (double)(MathHelper.cos(this.rotationYaw / 180.0F * (float)Math.PI) * 0.16F);
  posZ-=1.0D * (double)(MathHelper.sin(this.rotationYaw / 180.0F * (float)Math.PI) * 0.16F);
  motionX=motionY=motionZ=0.0D;
  double p_i1760_8_=player.getLookVec().xCoord;
  double p_i1760_10_=player.getLookVec().yCoord;
  double p_i1760_12_=player.getLookVec().zCoord;
  double d6=(double)MathHelper.sqrt_double(p_i1760_8_ * p_i1760_8_ + p_i1760_10_ * p_i1760_10_ + p_i1760_12_ * p_i1760_12_);
  motionX=p_i1760_8_ / d6 * 1.0D;
  motionY=p_i1760_10_ / d6 * 1.0D;
  motionZ=p_i1760_12_ / d6 * 1.0D;
  displayRotationYaw=rotationYaw;
  float f3=MathHelper.sqrt_double(motionX * motionX + motionZ * motionZ);
  displayRotationPitch=(float)(Math.atan2(motionY,(double)f3) * 180.0D / Math.PI);
}

Fixed version (ground truth):
public EntityRocket(World world,EntityPlayer player,float par4,float size){
  super(world);
  inputParam4=par4;
  shootingEntity=player;
  explosionSize=size;
  setSize(0.25F,0.25F);
  setLocationAndAngles(player.posX,player.posY + (double)player.getEyeHeight(),player.posZ,player.rotationYaw + ((itemRand.nextFloat() - 0.5F) * par4 * 15F),player.rotationPitch + ((itemRand.nextFloat() - 0.5F) * par4 * 15F));
  setPosition(this.posX,this.posY,this.posZ);
  posX-=1.0D * (double)(MathHelper.cos(this.rotationYaw / 180.0F * (float)Math.PI) * 0.16F);
  posZ-=1.0D * (double)(MathHelper.sin(this.rotationYaw / 180.0F * (float)Math.PI) * 0.16F);
  motionX=motionY=motionZ=0.0D;
  double p_i1760_8_=player.getLookVec().x;
  double p_i1760_10_=player.getLookVec().y;
  double p_i1760_12_=player.getLookVec().z;
  double d6=(double)MathHelper.sqrt(p_i1760_8_ * p_i1760_8_ + p_i1760_10_ * p_i1760_10_ + p_i1760_12_ * p_i1760_12_);
  motionX=p_i1760_8_ / d6 * 1.0D;
  motionY=p_i1760_10_ / d6 * 1.0D;
  motionZ=p_i1760_12_ / d6 * 1.0D;
  displayRotationYaw=rotationYaw;
  float f3=MathHelper.sqrt(motionX * motionX + motionZ * motionZ);
  displayRotationPitch=(float)(Math.atan2(motionY,(double)f3) * 180.0D / Math.PI);
}
Program: 22243
Project: 22243
Buggy source:
protected void onImpact(){
  if (!this.worldObj.isRemote) {
    newExplosion(worldObj,shootingEntity,posX,posY,posZ,explosionSize,true,worldObj.getGameRules().getBoolean("String_Node_Str"));
    this.setDead();
  }
}

Fixed version (ground truth):
protected void onImpact(){
  if (!this.world.isRemote) {
    newExplosion(world,shootingEntity,posX,posY,posZ,explosionSize,true,world.getGameRules().getBoolean("String_Node_Str"));
    this.setDead();
  }
}
Program: 22244
Project: 22244
Buggy source:
@Override public boolean attackEntityFrom(DamageSource source,float amount){
  if (isEntityInvulnerable(source)) {
    return false;
  }
 else {
    setBeenAttacked();
    Entity entity=source.getEntity();
    if (entity != null) {
      Vec3d vec3=entity.getLookVec();
      motionX=vec3.xCoord;
      motionY=vec3.yCoord;
      motionZ=vec3.zCoord;
      if (entity instanceof EntityLivingBase) {
        shootingEntity=(EntityLivingBase)entity;
      }
      return true;
    }
 else {
      return false;
    }
  }
}

Fixed version (ground truth):
@Override public boolean attackEntityFrom(DamageSource source,float amount){
  if (isEntityInvulnerable(source)) {
    return false;
  }
 else {
    setBeenAttacked();
    Entity entity=source.getTrueSource();
    if (entity != null) {
      Vec3d vec3=entity.getLookVec();
      motionX=vec3.x;
      motionY=vec3.y;
      motionZ=vec3.z;
      if (entity instanceof EntityLivingBase) {
        shootingEntity=(EntityLivingBase)entity;
      }
      return true;
    }
 else {
      return false;
    }
  }
}
Program: 22246
Project: 22246
Buggy source:
/** 
 * @see ExosuitUpgrade#getAttributeModifiersForExosuit(EntityEquipmentSlot,ItemStack)
 */
public Multimap<String,AttributeModifier> getAttributeModifiersForExosuit(EntityEquipmentSlot armorSlot,ItemStack armorPieceStack){
  return HashMultimap.create();
}

Fixed version (ground truth):
/** 
 * @see ExosuitUpgrade#getAttributeModifiersForExosuit(EntityEquipmentSlot,ItemStack)
 */
public Multimap<String,AttributeModifier> getAttributeModifiersForExosuit(EntityEquipmentSlot armorSlot,@Nonnull ItemStack armorPieceStack){
  return HashMultimap.create();
}
Program: 22247
Project: 22247
Buggy source:
@Override public boolean getIsRepairable(ItemStack toRepair,ItemStack repair){
  if (repairMaterial instanceof ItemStack) {
    return repair.isItemEqual((ItemStack)repairMaterial) || super.getIsRepairable(toRepair,repair);
  }
  if (repairMaterial instanceof String) {
    return ItemStackUtility.isItemOreDictedAs(repair,(String)repairMaterial) || super.getIsRepairable(toRepair,repair);
  }
  return super.getIsRepairable(toRepair,repair);
}

Fixed version (ground truth):
@Override public boolean getIsRepairable(ItemStack toRepair,@Nullable ItemStack repair){
  if (repairMaterial instanceof ItemStack && repair != null) {
    return repair.isItemEqual((ItemStack)repairMaterial) || super.getIsRepairable(toRepair,repair);
  }
  if (repairMaterial instanceof String) {
    return ItemStackUtility.isItemOreDictedAs(repair,(String)repairMaterial) || super.getIsRepairable(toRepair,repair);
  }
  return super.getIsRepairable(toRepair,repair);
}
Program: 22248
Project: 22248
Buggy source:
@Override public void updateModel(ModelBiped parentModel,EntityLivingBase entityLivingBase,ItemStack itemStack,ModelExosuitUpgrade modelExosuitUpgrade){
}

Fixed version (ground truth):
@Override public void updateModel(ModelBiped parentModel,EntityLivingBase entityLivingBase,@Nonnull ItemStack itemStack,ModelExosuitUpgrade modelExosuitUpgrade){
}
Program: 22249
Project: 22249
Buggy source:
@SubscribeEvent @SideOnly(Side.CLIENT) public void onPlayerTick(TickEvent.ClientTickEvent event){
  Minecraft mc=Minecraft.getMinecraft();
  if (event.side == Side.CLIENT && mc.player != null) {
    if (event.phase == TickEvent.Phase.START) {
      return;
    }
    for (    EntityEquipmentSlot slot : ItemStackUtility.ARMOR_SLOTS) {
      ItemStack armorStack=mc.player.getItemStackFromSlot(slot);
      if (armorStack != null && armorType.isAssignableFrom(armorStack.getItem().getClass())) {
        getModel(mc.player,slot).updateModel(mc.player,armorStack,slot);
      }
    }
  }
}

Fixed version (ground truth):
@SubscribeEvent @SideOnly(Side.CLIENT) public void onPlayerTick(TickEvent.ClientTickEvent event){
  Minecraft mc=Minecraft.getMinecraft();
  if (event.side == Side.CLIENT && mc.player != null) {
    if (event.phase == TickEvent.Phase.START) {
      return;
    }
    for (    EntityEquipmentSlot slot : ItemStackUtility.ARMOR_SLOTS) {
      ItemStack armorStack=mc.player.getItemStackFromSlot(slot);
      if (armorType.isAssignableFrom(armorStack.getItem().getClass())) {
        getModel(mc.player,slot).updateModel(mc.player,armorStack,slot);
      }
    }
  }
}
Program: 22250
Project: 22250
Buggy source:
@Override public ItemStack decrStackSize(ItemStack me,int slot,int size){
  NBTTagCompound plateNBT=getPlateNBT(me);
  if (plateNBT != null) {
    ItemStack toBeRemoved=new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
    me.getTagCompound().removeTag("String_Node_Str");
    return toBeRemoved;
  }
  return null;
}

Fixed version (ground truth):
@Nonnull @Override public ItemStack decrStackSize(@Nonnull ItemStack me,int slot,int size){
  NBTTagCompound plateNBT=getPlateNBT(me);
  if (plateNBT != null) {
    ItemStack toBeRemoved=new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
    me.getTagCompound().removeTag("String_Node_Str");
    return toBeRemoved;
  }
  return ItemStack.EMPTY;
}
Program: 22251
Project: 22251
Buggy source:
@Override public ArmorProperties getProperties(EntityLivingBase player,ItemStack armor,DamageSource source,double damage,int slot){
  return null;
}

Fixed version (ground truth):
@Override public ArmorProperties getProperties(EntityLivingBase player,@Nonnull ItemStack armor,DamageSource source,double damage,int slot){
  return null;
}
Program: 22252
Project: 22252
Buggy source:
@Override public ItemStack getStackInSlot(ItemStack me,int slot){
  NBTTagCompound plateNBT=getPlateNBT(me);
  if (plateNBT != null) {
    return new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
  }
  return null;
}

Fixed version (ground truth):
@Nonnull @Override public ItemStack getStackInSlot(@Nonnull ItemStack me,int slot){
  NBTTagCompound plateNBT=getPlateNBT(me);
  if (plateNBT != null) {
    return new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
  }
  return ItemStack.EMPTY;
}
Program: 22253
Project: 22253
Buggy source:
@Override public void setInventorySlotContents(ItemStack me,int slot,ItemStack stack){
  if (stack == null && me.hasTagCompound()) {
    me.getTagCompound().removeTag("String_Node_Str");
    return;
  }
  if (!me.hasTagCompound()) {
    me.setTagCompound(new NBTTagCompound());
  }
  ExosuitPlate plate=UtilPlates.getPlate(stack);
  if (plate != null) {
    NBTTagCompound plateNBT=new NBTTagCompound();
    plateNBT.setString("String_Node_Str",plate.getIdentifier());
    plateNBT.setTag("String_Node_Str",stack.writeToNBT(new NBTTagCompound()));
    me.getTagCompound().setTag("String_Node_Str",plateNBT);
  }
}

Fixed version (ground truth):
@Override public void setInventorySlotContents(@Nonnull ItemStack me,int slot,@Nonnull ItemStack stack){
  if (stack.isEmpty() && me.hasTagCompound()) {
    me.getTagCompound().removeTag("String_Node_Str");
    return;
  }
  if (!me.hasTagCompound()) {
    me.setTagCompound(new NBTTagCompound());
  }
  ExosuitPlate plate=UtilPlates.getPlate(stack);
  if (plate != null) {
    NBTTagCompound plateNBT=new NBTTagCompound();
    plateNBT.setString("String_Node_Str",plate.getIdentifier());
    plateNBT.setTag("String_Node_Str",stack.writeToNBT(new NBTTagCompound()));
    me.getTagCompound().setTag("String_Node_Str",plateNBT);
  }
}
Program: 22254
Project: 22254
Buggy source:
@Override public boolean canPutInSlot(ItemStack me,int slotNum,ItemStack upgrade){
  return UtilPlates.getPlate(upgrade) != null;
}

Fixed version (ground truth):
@Override public boolean canPutInSlot(@Nonnull ItemStack me,int slotNum,@Nonnull ItemStack upgrade){
  return UtilPlates.getPlate(upgrade) != null;
}
Program: 22255
Project: 22255
Buggy source:
@Nonnull @Override public ExosuitEventHandler[] getInstalledEventHandlers(ItemStack self){
  NBTTagCompound plateNBT=getPlateNBT(self);
  if (plateNBT != null) {
    ExosuitPlate plate=UtilPlates.getPlate(plateNBT.getString("String_Node_Str"));
    return new ExosuitEventHandler[]{plate};
  }
  return new ExosuitEventHandler[0];
}

Fixed version (ground truth):
@Nonnull @Override public ExosuitEventHandler[] getInstalledEventHandlers(@Nonnull ItemStack self){
  NBTTagCompound plateNBT=getPlateNBT(self);
  if (plateNBT != null) {
    ExosuitPlate plate=UtilPlates.getPlate(plateNBT.getString("String_Node_Str"));
    return new ExosuitEventHandler[]{plate};
  }
  return new ExosuitEventHandler[0];
}
Program: 22256
Project: 22256
Buggy source:
@Override public void damageArmor(EntityLivingBase entity,ItemStack stack,DamageSource source,int damage,int slot){
  NBTTagCompound plateNBT=getPlateNBT(stack);
  if (plateNBT != null) {
    ExosuitPlate plate=UtilPlates.getPlate(plateNBT.getString("String_Node_Str"));
    int damageReduction=plate.getDamageReductionAmount(armorType,source);
    if ((entity.world.rand.nextInt(20 - damage) + 1) > damageReduction) {
      if (plateNBT.hasKey("String_Node_Str")) {
        plateNBT.setInteger("String_Node_Str",plateNBT.getInteger("String_Node_Str") - 1);
      }
 else {
        plateNBT.setInteger("String_Node_Str",plate.getDamageReductionAmount(armorType,DamageSource.GENERIC));
      }
    }
  }
}

Fixed version (ground truth):
@Override public void damageArmor(EntityLivingBase entity,@Nonnull ItemStack stack,DamageSource source,int damage,int slot){
  NBTTagCompound plateNBT=getPlateNBT(stack);
  if (plateNBT != null) {
    ExosuitPlate plate=UtilPlates.getPlate(plateNBT.getString("String_Node_Str"));
    int damageReduction=plate.getDamageReductionAmount(armorType,source);
    if ((entity.world.rand.nextInt(20 - damage) + 1) > damageReduction) {
      if (plateNBT.hasKey("String_Node_Str")) {
        plateNBT.setInteger("String_Node_Str",plateNBT.getInteger("String_Node_Str") - 1);
      }
 else {
        plateNBT.setInteger("String_Node_Str",plate.getDamageReductionAmount(armorType,DamageSource.GENERIC));
      }
    }
  }
}
Program: 22257
Project: 22257
Buggy source:
@Override public boolean getIsRepairable(ItemStack toRepair,ItemStack repair){
  return false;
}

Fixed version (ground truth):
@Override public boolean getIsRepairable(ItemStack toRepair,@Nullable ItemStack repair){
  return false;
}
Program: 22258
Project: 22258
Buggy source:
@Override public void addInformation(ItemStack stack,EntityPlayer playerIn,List<String> tooltip,boolean advanced){
  NBTTagCompound plateNBT=getPlateNBT(stack);
  if (plateNBT != null) {
    ItemStack plateStack=new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
    if (plateStack != null) {
      tooltip.add(TextFormatting.BLUE + plateStack.getDisplayName());
    }
  }
  super.addInformation(stack,playerIn,tooltip,advanced);
}

Fixed version (ground truth):
@Override public void addInformation(ItemStack stack,EntityPlayer playerIn,List<String> tooltip,boolean advanced){
  NBTTagCompound plateNBT=getPlateNBT(stack);
  if (plateNBT != null) {
    ItemStack plateStack=new ItemStack(plateNBT.getCompoundTag("String_Node_Str"));
    if (!plateStack.isEmpty()) {
      tooltip.add(TextFormatting.BLUE + plateStack.getDisplayName());
    }
  }
  super.addInformation(stack,playerIn,tooltip,advanced);
}
Program: 22259
Project: 22259
Buggy source:
@Override public int getArmorDisplay(EntityPlayer player,ItemStack armor,int slot){
  NBTTagCompound plateNBT=getPlateNBT(armor);
  if (plateNBT != null) {
    return UtilPlates.getPlate(plateNBT.getString("String_Node_Str")).getDamageReductionAmount(armorType,DamageSource.GENERIC);
  }
  return ArmorMaterial.LEATHER.getDamageReductionAmount(armorType);
}

Fixed version (ground truth):
@Override public int getArmorDisplay(EntityPlayer player,@Nonnull ItemStack armor,int slot){
  NBTTagCompound plateNBT=getPlateNBT(armor);
  if (plateNBT != null) {
    return UtilPlates.getPlate(plateNBT.getString("String_Node_Str")).getDamageReductionAmount(armorType,DamageSource.GENERIC);
  }
  return ArmorMaterial.LEATHER.getDamageReductionAmount(armorType);
}
Program: 22260
Project: 22260
Buggy source:
@Nonnull @Override public ExosuitUpgrade[] getUpgrades(ItemStack self){
  return new ExosuitUpgrade[0];
}

Fixed version (ground truth):
@Nonnull @Override public ExosuitUpgrade[] getUpgrades(@Nonnull ItemStack self){
  return new ExosuitUpgrade[0];
}
Program: 22261
Project: 22261
Buggy source:
@Override public boolean hasUpgrade(ItemStack me,Item check){
  NBTTagCompound plateNBT=getPlateNBT(me);
  return plateNBT != null && new ItemStack(plateNBT.getCompoundTag("String_Node_Str")).getItem() == check;
}

Fixed version (ground truth):
@Override public boolean hasUpgrade(@Nonnull ItemStack me,Item check){
  NBTTagCompound plateNBT=getPlateNBT(me);
  return plateNBT != null && new ItemStack(plateNBT.getCompoundTag("String_Node_Str")).getItem() == check;
}
Program: 22262
Project: 22262
Buggy source:
@Override public boolean isItemValidForSlot(ItemStack me,int slot,ItemStack var2){
  return true;
}

Fixed version (ground truth):
@Override public boolean isItemValidForSlot(@Nonnull ItemStack me,int slot,@Nonnull ItemStack var2){
  return true;
}
Program: 22263
Project: 22263
Buggy source:
@Override public ItemOverrideList getOverrides(){
  return LeatherExosuitItemOverrideList.INSTANCE;
}

Fixed version (ground truth):
@Nonnull @Override public ItemOverrideList getOverrides(){
  return LeatherExosuitItemOverrideList.INSTANCE;
}
Program: 22264
Project: 22264
Buggy source:
@Override public IBakedModel handleItemState(IBakedModel originalModel,ItemStack stack,World world,EntityLivingBase entity){
  ItemLeatherExosuitArmor armor=(ItemLeatherExosuitArmor)stack.getItem();
  List<ResourceLocation> locations=new ArrayList<>();
  locations.add(armor.getItemIconResource());
  ExosuitPlate plate=armor.getPlate(stack);
  if (plate != null) {
    locations.add(UtilPlates.getIconFromPlate(plate.getIdentifier(),armor));
  }
  LeatherExosuitItemBakedModel exosuitItemBakedModel=(LeatherExosuitItemBakedModel)originalModel;
  IModel processed=new LeatherExosuitItemModel(locations);
  String cacheKey=String.format("String_Node_Str",armor.getRegistryName(),plate);
  IBakedModel bakedModel=processed.bake(new SimpleModelState(exosuitItemBakedModel.getTransforms()),exosuitItemBakedModel.getFormat(),ModelLoader.defaultTextureGetter());
  exosuitItemBakedModel.cacheModel(cacheKey,bakedModel);
  return bakedModel;
}

Fixed version (ground truth):
@Nonnull @Override public IBakedModel handleItemState(@Nonnull IBakedModel originalModel,ItemStack stack,World world,EntityLivingBase entity){
  ItemLeatherExosuitArmor armor=(ItemLeatherExosuitArmor)stack.getItem();
  List<ResourceLocation> locations=new ArrayList<>();
  locations.add(armor.getItemIconResource());
  ExosuitPlate plate=armor.getPlate(stack);
  if (plate != null) {
    locations.add(UtilPlates.getIconFromPlate(plate.getIdentifier(),armor));
  }
  LeatherExosuitItemBakedModel exosuitItemBakedModel=(LeatherExosuitItemBakedModel)originalModel;
  IModel processed=new LeatherExosuitItemModel(locations);
  String cacheKey=String.format("String_Node_Str",armor.getRegistryName(),plate);
  IBakedModel bakedModel=processed.bake(new SimpleModelState(exosuitItemBakedModel.getTransforms()),exosuitItemBakedModel.getFormat(),ModelLoader.defaultTextureGetter());
  exosuitItemBakedModel.cacheModel(cacheKey,bakedModel);
  return bakedModel;
}
Program: 22265
Project: 22265
Buggy source:
@Override public void updateModel(EntityLivingBase entityLivingBase,ItemStack itemStack,EntityEquipmentSlot slot){
  ItemStack stack=((Engineerable)itemStack.getItem()).getStackInSlot(itemStack,0);
  if (stack != null) {
    ExosuitPlate plate=UtilPlates.getPlate(stack);
    if (plate != null) {
      plateOverlay=new ResourceLocation(MODEL_TEXTURE.getResourceDomain(),MODEL_TEXTURE.getResourcePath().replace("String_Node_Str","String_Node_Str" + plate.getArmorMod() + "String_Node_Str"));
      return;
    }
  }
  plateOverlay=null;
}

Fixed version (ground truth):
@Override public void updateModel(EntityLivingBase entityLivingBase,ItemStack itemStack,EntityEquipmentSlot slot){
  ItemStack stack=((Engineerable)itemStack.getItem()).getStackInSlot(itemStack,0);
  ExosuitPlate plate=UtilPlates.getPlate(stack);
  if (plate != null) {
    plateOverlay=new ResourceLocation(MODEL_TEXTURE.getResourceDomain(),MODEL_TEXTURE.getResourcePath().replace("String_Node_Str","String_Node_Str" + plate.getArmorMod() + "String_Node_Str"));
    return;
  }
  plateOverlay=null;
}
Program: 22266
Project: 22266
Buggy source:
@Override public void render(Entity entity,float limbSwing,float limbSwingAmount,float ageInTicks,float netHeadYaw,float headPitch,float scale){
  super.render(entity,limbSwing,limbSwingAmount,ageInTicks,netHeadYaw,headPitch,scale);
  if (plateOverlay != null) {
    Minecraft.getMinecraft().renderEngine.bindTexture(plateOverlay);
  }
  GlStateManager.pushMatrix();
  copyRotateAngles(footLeft,bipedLeftLeg);
  copyRotateAngles(footRight,bipedRightLeg);
  copyRotateAngles(pauldronLeft,bipedLeftArm);
  copyRotateAngles(pauldronRight,bipedRightArm);
  copyRotateAngles(breastPlate,bipedBody);
  if (entity.isSneaking()) {
    GlStateManager.translate(0,0.2F,0);
  }
  footLeft.render(scale);
  footRight.render(scale);
  pauldronLeft.render(scale);
  pauldronRight.render(scale);
  breastPlate.render(scale);
  GlStateManager.popMatrix();
}

Fixed version (ground truth):
@Override public void render(@Nullable Entity entity,float limbSwing,float limbSwingAmount,float ageInTicks,float netHeadYaw,float headPitch,float scale){
  super.render(entity,limbSwing,limbSwingAmount,ageInTicks,netHeadYaw,headPitch,scale);
  if (plateOverlay != null) {
    Minecraft.getMinecraft().renderEngine.bindTexture(plateOverlay);
  }
  GlStateManager.pushMatrix();
  copyRotateAngles(footLeft,bipedLeftLeg);
  copyRotateAngles(footRight,bipedRightLeg);
  copyRotateAngles(pauldronLeft,bipedLeftArm);
  copyRotateAngles(pauldronRight,bipedRightArm);
  copyRotateAngles(breastPlate,bipedBody);
  if (entity != null && entity.isSneaking()) {
    GlStateManager.translate(0,0.2F,0);
  }
  footLeft.render(scale);
  footRight.render(scale);
  pauldronLeft.render(scale);
  pauldronRight.render(scale);
  breastPlate.render(scale);
  GlStateManager.popMatrix();
}
Program: 22267
Project: 22267
Buggy source:
@Override public void onPlayerPickupXP(PlayerPickupXpEvent event,ItemStack armorStack,EntityEquipmentSlot slot){
  event.getOrb().xpValue=MathHelper.ceil(event.getOrb().xpValue * 1.125F);
}

Fixed version (ground truth):
@Override public void onPlayerPickupXP(PlayerPickupXpEvent event,@Nonnull ItemStack armorStack,EntityEquipmentSlot slot){
  event.getOrb().xpValue=MathHelper.ceil(event.getOrb().xpValue * 1.125F);
}
Program: 22268
Project: 22268
Buggy source:
@Override public void onPlayerPickupXP(PlayerPickupXpEvent event,ItemStack armorStack,EntityEquipmentSlot slot){
  event.getOrb().xpValue=MathHelper.ceil(event.getOrb().xpValue * 1.25F);
}

Fixed version (ground truth):
@Override public void onPlayerPickupXP(PlayerPickupXpEvent event,@Nonnull ItemStack armorStack,EntityEquipmentSlot slot){
  event.getOrb().xpValue=MathHelper.ceil(event.getOrb().xpValue * 1.25F);
}