public Bundle minus(Bundle goal) {
		Bundle diff = new Bundle();
		for(ResourcePile have:contents){
			ResourcePile copy = new ResourcePile(have);
			for(ResourcePile used:goal){
				if (copy.type == used.type){
					copy.amount -= used.amount;
					if (copy.amount < 0) copy.amount = 0D;
					break;
				}
			}
			if (copy.amount > 0) diff.insert(copy);
		}
		return diff;
	}