public SlotType(String type) {
		reward = new HashMap<ItemStack,Integer>();
		fireworks = new HashMap<ItemStack,Integer>();
		wrg = new WeightedRandomGenerator();
		
		String typeNode = "types."+type;
		String rewardNode = typeNode+".reward";
		
		cost = Global.config().getInt(typeNode + ".cost");
		
		Set<String> keys = null;
		keys = Global.config().getConfigurationSection(rewardNode).getKeys(false);
		for(String k : keys) {
			String[] data = k.split(",");
			ItemStack match = null;
			if(data.length < 2) break;
			if(data.length == 2) match = new ItemStack(Integer.parseInt(data[0]),1,Short.parseShort(data[1]));
			
			reward.put(match,Global.config().getInt(rewardNode+"."+k+".money"));
			fireworks.put(match,Global.config().getInt(rewardNode+"."+k+".fireworks"));
			cmds.put(match,new ArrayList<String>(Global.config().getStringList(rewardNode+"."+k+".cmd")));
		}
		
		for(Integer w : Global.config().getIntegerList(typeNode+".items")) {
			for(String s: Global.config().getStringList(typeNode+".items."+w)) {
				String[] data = s.split(",");
				ItemStack i = null;
				if(data.length < 2) break;
				if(data.length == 2) i = new ItemStack(Integer.parseInt(data[0]),1,Short.parseShort(data[1]));
				wrg.add(i, w);
			}
		}
	}