|  |  | @ -23,10 +23,10 @@ import java.util.regex.Pattern; | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  | public class PowersParser { |  |  |  | public class PowersParser { | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     private static String powersPath = ConfigManager.DEFAULT_DATA_DIR + "wpak/Powers.cfg"; |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |     private static final Pattern POWER_REGEX = Pattern.compile("(?<=POWERBEGIN)(.+?)(?=POWEREND)", Pattern.DOTALL); |  |  |  |     private static final Pattern POWER_REGEX = Pattern.compile("(?<=POWERBEGIN)(.+?)(?=POWEREND)", Pattern.DOTALL); | 
			
		
	
		
		
			
				
					
					|  |  |  |     private static final Pattern STRSPLIT_REGEX = Pattern.compile("([^\"]\\S*|\"[^\"]*\")\\s*"); |  |  |  |     private static final Pattern STRSPLIT_REGEX = Pattern.compile("([^\"]\\S*|\"[^\"]*\")\\s*"); | 
			
		
	
		
		
			
				
					
					|  |  |  |     private static final Pattern CONDITION_REGEX = Pattern.compile("(?<=CONDITIONBEGIN)(.+?)(?=CONDITIONEND)", Pattern.DOTALL); |  |  |  |     private static final Pattern CONDITION_REGEX = Pattern.compile("(?<=CONDITIONBEGIN)(.+?)(?=CONDITIONEND)", Pattern.DOTALL); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |     private static final String powersPath = ConfigManager.DEFAULT_DATA_DIR + "wpak/Powers.cfg"; | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     public static void parseWpakFile() throws IOException { |  |  |  |     public static void parseWpakFile() throws IOException { | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
	
		
		
			
				
					|  |  | @ -203,7 +203,6 @@ public class PowersParser { | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |                         equipmentPreReq.slot = mbEnums.EquipSlotType.valueOf(args.get(0)); |  |  |  |                         equipmentPreReq.slot = mbEnums.EquipSlotType.valueOf(args.get(0)); | 
			
		
	
		
		
			
				
					
					|  |  |  |                         equipmentPreReq.skill = args.get(1).replaceAll("\"", ""); |  |  |  |                         equipmentPreReq.skill = args.get(1).replaceAll("\"", ""); | 
			
		
	
		
		
			
				
					
					|  |  |  |                         ; |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |                         equipmentPreReq.level = Integer.parseInt(args.get(2)); |  |  |  |                         equipmentPreReq.level = Integer.parseInt(args.get(2)); | 
			
		
	
		
		
			
				
					
					|  |  |  |                         powerEntry.equipmentPreReq = equipmentPreReq; |  |  |  |                         powerEntry.equipmentPreReq = equipmentPreReq; | 
			
		
	
		
		
			
				
					
					|  |  |  |                         break; |  |  |  |                         break; | 
			
		
	
	
		
		
			
				
					|  |  | @ -289,6 +288,15 @@ public class PowersParser { | 
			
		
	
		
		
			
				
					
					|  |  |  |                 } |  |  |  |                 } | 
			
		
	
		
		
			
				
					
					|  |  |  |             } |  |  |  |             } | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             // Parse power conditions
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             String[] conditions = conditionString.toString().split("\n"); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             for (String condition : conditions) { | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |                 String[] parameters = condition.trim().split("\\s+"); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |                 powerEntry.conditions.put(parameters[0], Float.parseFloat(parameters[1])); | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             } | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         } catch (Exception e) { |  |  |  |         } catch (Exception e) { | 
			
		
	
		
		
			
				
					
					|  |  |  |             Logger.error(powerEntry.power_id + " " + e); |  |  |  |             Logger.error(powerEntry.power_id + " " + e); | 
			
		
	
		
		
			
				
					
					|  |  |  |         } |  |  |  |         } | 
			
		
	
	
		
		
			
				
					|  |  | 
 |