Dear Marlies,
Thank you for those further explanations. If I understand you correctly, each product has a code (assigned as dummy weight) and the shipment costs of the order are calculated from the product with the highest code in the order.
E.g.
Product A: Weight 1; 5 pieces ordered
Product B: Weight 3; 1 piece ordered
Product C: Weight 3; 15 pieces ordered
In this case, the shipping cost is for category 3, and the quantities of the products is irrelevant for the calculation of the shipping costs.
To solve this, you can simply use the MaxWeight variable rather than Weight (which gives the sum of all dummy weight values).
In my example, MaxWeight will have a value of 3 and thus result in 24,95€ shipping, while in your original example, the second product will have weight code 2 (which is the maximum of 1 and 2), so the shipping will be 6,95€.
The rather straightforward rules in this case are:
Name=Shipping class 1; MaxWeight<=1; Shipping=2
Name=Shipping class 2; MaxWeight<=2; Shipping=6.95
Name=Shipping class 3; MaxWeight<=3; Shipping=24.95
Your issue with "collect at our shop" is ideally solved with two shipping methods: One method that offers "Collect at your shop" with 0 shipping costs. That method can either use my plugin, or even the standard shipping module included in VM. And then you have the "Shipping by Rules"-based method as given above, with just an additional, prepended rule that excludes all orders with that particular product from shipping at all. How do you identify that product / those products? You can either use a particular category, or you can identify individual products by their sku.
Excluding by SKU (here, two products with SKU "excluded-SKU1" and "excluded-SKU2" are excluded from shipping at all):
Comment=No shipping (product); Condition=contains_any(skus, "excluded-SKU1", "excluded-SKU2"); NoShipping
Name=Shipping class 1; MaxWeight<=1; ....
Excluding by Category (e.g. all products that require pickup are in Category with ID 42):
Comment=No shipping for a category; Condition=contains_any(categories, 42); NoShipping
Name=Shipping class 1; MaxWeight<=1; ....
It is important to put that exclusion rule first, because otherwise one of the other rules will match, and the plugin will always use the first matching rule.
Also note that in this case the "Condition=" is required, because the plugin is only able to automatically detect conditions if they contain any comparison operator (<, ==, >, <=, >=, etc.).
I hope this solves all your problems.
Best regards,
Reinhold