Program: 154271
Project: 154271
Buggy source:
private void addToCartAction(){
  if (currentlySelectedRadioButton == null)   messageTextField.setText("String_Node_Str");
 else {
    if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      int buildAmount=(Integer)buildTypeAmountSpinner.getValue();
      if (allowanceRemaining > 0) {
        if (playerSelectedDistrict.getTotalBlockCount() < 8) {
          if (buildAmount != 0) {
            if (buildAmount <= StructureFactory.getInstance().residentialCount) {
              cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount);
              buildList.setModel(cartListModel);
              for (int ii=0; ii < buildAmount; ii++) {
                StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
                System.out.println("String_Node_Str");
                playerSelectedDistrict.addResidentialBlock(1);
                System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
              }
              System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount+ "String_Node_Str");
              allowanceRemaining=allowanceRemaining - buildAmount;
              buildAllowanceTextField.setText("String_Node_Str" + allowanceRemaining + "String_Node_Str");
              projectedCosts=projectedCosts + playerSelectedDistrict.getResidentialCost() * buildAmount;
              totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
            }
 else             messageTextField.setText("String_Node_Str");
          }
 else           messageTextField.setText("String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      int buildAmount=(Integer)buildTypeAmountSpinner.getValue();
      if (allowanceRemaining > 0) {
        if (playerSelectedDistrict.getTotalBlockCount() < 8) {
          if (buildAmount != 0) {
            if (buildAmount <= StructureFactory.getInstance().industrialCount) {
              cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount);
              buildList.setModel(cartListModel);
              for (int ii=0; ii < buildAmount; ii++) {
                StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
                System.out.println("String_Node_Str");
                playerSelectedDistrict.addIndustrialBlock(1);
                System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
              }
              System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount+ "String_Node_Str");
              allowanceRemaining=allowanceRemaining - buildAmount;
              buildAllowanceTextField.setText("String_Node_Str" + allowanceRemaining + "String_Node_Str");
              projectedCosts=projectedCosts + playerSelectedDistrict.getIndustrialCost() * buildAmount;
              totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
            }
 else             messageTextField.setText("String_Node_Str");
          }
 else           messageTextField.setText("String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (allowanceRemaining != 0) {
        if (StructureFactory.getInstance().railroadCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          buildList.setModel(cartListModel);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          playerSelectedDistrict.addRailroad();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          allowanceRemaining=allowanceRemaining + 1;
          buildAllowanceTextField.setText("String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (playerSelectedDistrict.isStadiumed() == false) {
        if (StructureFactory.getInstance().stadiumCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          System.out.println("String_Node_Str");
          playerSelectedDistrict.addStadium();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          projectedCosts=projectedCosts + 2;
          totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (playerSelectedDistrict.isSkyScrapered() == false) {
        if (StructureFactory.getInstance().skyscraperCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          System.out.println("String_Node_Str");
          playerSelectedDistrict.addSkyscraper();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          projectedCosts=projectedCosts + playerSelectedDistrict.skyscraperCost;
          totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (StructureFactory.getInstance().monopolyTowerCount != 0) {
        cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
        System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
        StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
        System.out.println("String_Node_Str");
        playerSelectedDistrict.addMonopolyTower();
        System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
        projectedCosts=projectedCosts + 7;
        totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
      System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str");
      projectedCosts=projectedCosts + playerSelectedDistrict.hazard.getBlockCount() * .5;
      totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
    }
  }
}

Fixed version (ground truth):
private void addToCartAction(){
  if (currentlySelectedRadioButton == null)   messageTextField.setText("String_Node_Str");
 else {
    if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      int buildAmount=(Integer)buildTypeAmountSpinner.getValue();
      if (allowanceRemaining > 0) {
        if (playerSelectedDistrict.getTotalBlockCount() < 8) {
          if (buildAmount != 0) {
            if (buildAmount <= StructureFactory.getInstance().residentialCount) {
              cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount);
              buildList.setModel(cartListModel);
              for (int ii=0; ii < buildAmount; ii++) {
                StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
                System.out.println("String_Node_Str");
                playerSelectedDistrict.addResidentialBlock(1);
                System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
              }
              System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount+ "String_Node_Str");
              allowanceRemaining=allowanceRemaining - buildAmount;
              buildAllowanceTextField.setText("String_Node_Str" + allowanceRemaining + "String_Node_Str");
              projectedCosts=projectedCosts + playerSelectedDistrict.getResidentialCost() * buildAmount;
              totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
              clearRadio();
            }
 else             messageTextField.setText("String_Node_Str");
          }
 else           messageTextField.setText("String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      int buildAmount=(Integer)buildTypeAmountSpinner.getValue();
      if (allowanceRemaining > 0) {
        if (playerSelectedDistrict.getTotalBlockCount() < 8) {
          if (buildAmount != 0) {
            if (buildAmount <= StructureFactory.getInstance().industrialCount) {
              cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount);
              buildList.setModel(cartListModel);
              for (int ii=0; ii < buildAmount; ii++) {
                StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
                System.out.println("String_Node_Str");
                playerSelectedDistrict.addIndustrialBlock(1);
                System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
              }
              System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str"+ buildAmount+ "String_Node_Str");
              allowanceRemaining=allowanceRemaining - buildAmount;
              buildAllowanceTextField.setText("String_Node_Str" + allowanceRemaining + "String_Node_Str");
              projectedCosts=projectedCosts + playerSelectedDistrict.getIndustrialCost() * buildAmount;
              totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
              clearRadio();
            }
 else             messageTextField.setText("String_Node_Str");
          }
 else           messageTextField.setText("String_Node_Str");
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (allowanceRemaining != 0) {
        if (StructureFactory.getInstance().railroadCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          buildList.setModel(cartListModel);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          playerSelectedDistrict.addRailroad();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          allowanceRemaining=allowanceRemaining + 1;
          buildAllowanceTextField.setText("String_Node_Str");
          clearRadio();
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (playerSelectedDistrict.isStadiumed() == false) {
        if (StructureFactory.getInstance().stadiumCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          System.out.println("String_Node_Str");
          playerSelectedDistrict.addStadium();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          projectedCosts=projectedCosts + 2;
          totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
          clearRadio();
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (playerSelectedDistrict.isSkyScrapered() == false) {
        if (StructureFactory.getInstance().skyscraperCount != 0) {
          cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
          StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
          System.out.println("String_Node_Str");
          playerSelectedDistrict.addSkyscraper();
          System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
          projectedCosts=projectedCosts + playerSelectedDistrict.skyscraperCost;
          totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
          clearRadio();
        }
 else         messageTextField.setText("String_Node_Str");
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      if (StructureFactory.getInstance().monopolyTowerCount != 0) {
        cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
        System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str"+ currentlySelectedRadioButton+ "String_Node_Str");
        StructureFactory.getInstance().get(StructureFactory.getInstance().getStructureByName("String_Node_Str"));
        System.out.println("String_Node_Str");
        playerSelectedDistrict.addMonopolyTower();
        System.out.println("String_Node_Str" + playerSelectedDistrict.getName());
        projectedCosts=projectedCosts + 7;
        totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
        clearRadio();
      }
 else       messageTextField.setText("String_Node_Str");
    }
 else     if (currentlySelectedRadioButton.compareToIgnoreCase("String_Node_Str") == 0) {
      cartListModel.addElement(playerSelectedDistrict.getName() + "String_Node_Str" + currentlySelectedRadioButton);
      System.out.println("String_Node_Str" + playerSelectedDistrict.getName() + "String_Node_Str");
      projectedCosts=projectedCosts + playerSelectedDistrict.hazard.getBlockCount() * .5;
      totalTextField.setText("String_Node_Str" + projectedCosts + "String_Node_Str");
    }
  }
}