Any ideas on how to set/output something if the previous variant in a for loop has a parameter?
Check out the MN Twig Perversion plugin. It adds a break Twig tag, which allows you to escape from a loop once you have the data you need.