public static void loadPreferences(File prefSet) {
		if (loadFrom == null){
			try {
				loadFrom = prefSet;
				Scanner lineIter = new Scanner(prefSet);
				lineIter.useDelimiter(",\n?");
				String flag = null;
				double value = 0;
				int i = 0;
				Preferences insert = new Preferences();
				while (lineIter.hasNext()){
					try{
					flag = lineIter.next();	//gets a pair
					value = lineIter.nextDouble();
					}catch(Exception e)
					{
						e.printStackTrace();
					}
					insert.put(Enum.valueOf(Preference.class, flag), value);
					if (i%Preference.values().length == Preference.values().length - 1){
						//insert.put(Preference.smallestAlloc, 0.01); i++;	//temporary to load new value type.
						loaded.add(insert);
						insert = new Preferences();
					}
					i++;
				}
				lineIter.close();
			} catch (FileNotFoundException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
		}
	}