|
|
@ -102,9 +102,34 @@ public void LOAD_ALL_ITEM_REQUIREMENTS(){ |
|
|
|
PreparedStatement preparedStatement = connection.prepareStatement("SELECT * FROM static_item_requirements WHERE 'itemID' = ?")) { |
|
|
|
PreparedStatement preparedStatement = connection.prepareStatement("SELECT * FROM static_item_requirements WHERE 'itemID' = ?")) { |
|
|
|
preparedStatement.setInt(1, itemBase.getUUID()); |
|
|
|
preparedStatement.setInt(1, itemBase.getUUID()); |
|
|
|
ResultSet rs = preparedStatement.executeQuery(); |
|
|
|
ResultSet rs = preparedStatement.executeQuery(); |
|
|
|
//while(rs.next()) {
|
|
|
|
while(rs.next()) { |
|
|
|
itemBase.LoadRequirements(rs.getString("racesRequired"), rs.getString("racesRestricted"), rs.getString("classesRequired"), rs.getString("classesRestricted"), rs.getString("discsRequired"), rs.getString("discsRestricted")); |
|
|
|
|
|
|
|
//}
|
|
|
|
String racesRequired = ""; |
|
|
|
|
|
|
|
if(rs.getString("racesRequired") != null) |
|
|
|
|
|
|
|
racesRequired = rs.getString("racesRequired"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String racesRestricted = ""; |
|
|
|
|
|
|
|
if(rs.getString("racesRestricted") != null) |
|
|
|
|
|
|
|
racesRestricted = rs.getString("racesRestricted"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String classesRequired = ""; |
|
|
|
|
|
|
|
if(rs.getString("classesRequired") != null) |
|
|
|
|
|
|
|
classesRequired = rs.getString("classesRequired"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String classesRestricted = ""; |
|
|
|
|
|
|
|
if(rs.getString("classesRestricted") != null) |
|
|
|
|
|
|
|
classesRestricted = rs.getString("classesRestricted"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String discsRequired = ""; |
|
|
|
|
|
|
|
if(rs.getString("discsRequired") != null) |
|
|
|
|
|
|
|
discsRequired = rs.getString("discsRequired"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String discsRestricted = ""; |
|
|
|
|
|
|
|
if(rs.getString("discsRestricted") != null) |
|
|
|
|
|
|
|
discsRestricted = rs.getString("discsRestricted"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
itemBase.LoadRequirements(racesRequired,racesRestricted,classesRequired, classesRestricted, discsRequired, discsRestricted); |
|
|
|
|
|
|
|
} |
|
|
|
} catch (SQLException e) { |
|
|
|
} catch (SQLException e) { |
|
|
|
Logger.error("No Entry In static_item_requirements for item UUID: " + itemBase.getUUID()); |
|
|
|
Logger.error("No Entry In static_item_requirements for item UUID: " + itemBase.getUUID()); |
|
|
|
} |
|
|
|
} |
|
|
|