To limit the number of values a customer can select, in the backend, set a Maximum Selection, e.g. Maximum of 3 toppings allowed.
On the POS, if the user tries to select more options than what is defined, they will see an error.
Using "Maximum Selection" in a Product Variant Group