add_filter( 'woocommerce_is_sold_individually', 'product_max_1_cart_custom_field', 9999, 2 );
function product_max_1_cart_custom_field( $individually, $product ) {
$acf_field_value = get_field( 'acf_field_id', $product->get_id() );
if ( $acf_field_value && 'whatever' == $acf_field_value ) {
$individually = true;
}
return $individually;
}