query: #defaultView:Graph
  SELECT ?item1 ?image1 ?item1Label ?rgb ?item2 ?image2 ?item2Label ?edgeLabel
  
  WITH {
    SELECT ?item1 ?rgb WHERE {
      {
        SELECT (?character as ?item1) WHERE {
          ?game wdt:P31 wd:Q7889.
          ?game wdt:P179 wd:Q219623.
          ?game wdt:P674 ?character.
        }
      }
      UNION
      {
        # Find sport -
        SELECT (?sport as ?item1) WHERE {
          ?game wdt:P31 wd:Q7889.
          ?game wdt:P179 wd:Q219623.
          ?game wdt:P674 ?character.
          ?character wdt:P641 ?sport.
        }
      }
      UNION
      {
        # Find games
        SELECT (?game as ?item1) ?rgb WHERE {
          ?game wdt:P31 wd:Q7889.
          ?game wdt:P179 wd:Q219623.  
          BIND("7FFF00" as ?rgb)
        }
      }
  
    }
  } AS %item1
  WITH {
    SELECT (?item1 AS ?item2) WHERE {
      INCLUDE %item1.
    }
  } AS %item2
  WHERE {
    INCLUDE %item1 .
    INCLUDE %item2 .
    ?item1 ?wdt ?item2 .
    ?edge wikibase:directClaim ?wdt;
          a wikibase:Property .
    OPTIONAL { ?item1 wdt:P18 ?image1 . }
    OPTIONAL { ?item2 wdt:P18 ?image2 . }
    SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
  }