ShortCode to count amount of posts having certain Custom Field values as passed in a ShortCode attribute.

add_shortcode( 'count-siege-by-shortcode-attr', 'count_siege_by_attr' );

function count_siege_by_attr( $atts, $content = '' ) {
    
    //Hier bilden wir ein attribut für den shortcode, wo alle werte des sieges eingegeben werden, komma separiert.
    // beispiel: [count-siege-by-shortcode-attr type="Championsleague,Landesleague, Nationalcup, etc"]
    $a = shortcode_atts( [
                'type'   => false,
    ], $atts );

    //die ausgbe des ShortCodes ist erst mal leer
    $output = '';

    //falls wir ein Pokal Typ (type attribute) angeben, dann extrahieren wir dies und bilden ein array
    if ( $a['type'] ) {
        // Parse type into an array. Whitespace will be stripped.
        $a['type'] = array_map( 'trim', str_getcsv( $a['type'], ',' ) );
    }

    //nun holen wir uns alle posts von der datenbasis, post typ "siege", wo das feld text-veranstaltung eines der werte von Sieges Typ hat (type attribute). Wir tun dies mit WP_Query und shieben den array von sieges typen rein, um bloss die Posts zu holen welche wir wollen!
    $args = array(
	    'post_type' => 'post',
	    'meta_query' => array(
	       
	        array(
			    'key' => 'wpcf-our-field',//das ist das feld auf das wirt hören wollen
			    'value' => $a['type'],//$a['type'] haben wir weiter oben im attribut definiert!
			    'compare' => 'IN'
			),
	       //hier müssen etliche NEUE werte als neuer array (also so wie die obigen 2 beispiele) engefügt werden. Wir können damit immer helfen fals nötig
	    )
	);
	$query = new WP_Query( $args );

	//wir zählen alle posts die wir bekamen
    $total=count($query->posts);

    //und nun spucken wir die nummer in einer kette (gezählt) aus.
    $output .= $total;

    //Shortcode machen niemals ECHO, die machen immer RETURN
    return $output;
}

Use the ShortCode like this:
[count-siege-by-shortcode-attr type="Landespokal,Supercup,ETC"]