$("#id_deck80 .card_type_creatures").find("span.card_count").each(function(){ count_creature += parseInt($("#id_deck80").find("span.card_count").html()); });