title: SFML 2.0 – drawing with vector of sprites
body: <p>I'm trying to create a loop to draw 10 blocks on the screen, but nothing is showing. I got no error, so I think that the vector is not storing the sprites. I'm new to SFML, so I don't really know what I'm doing wrong.</p>
  
  <pre><code>sf::Texture bTexture;
  sf::Texture bloqueTexture;
  sf::Sprite bloqueSprite;
  
  //create vector of blocks
  std::vector&lt;sf::Sprite&gt; bricks(10, sf::Sprite(bloqueTexture));
  
  fondo.setTexture(img_mgr.getImage("fondo.jpg"));
  personaje.setTexture(img_mgr.getImage("jumper.png"));
  personaje.setPosition(100,POSICION_TERRENO_Y);
  bloqueSprite.setTexture(img_mgr.getImage("bloque.png"));
  bloqueTexture.loadFromFile("Recursos/imagenes/bloque.png");
  
  //Fill the vector with the texture
  for (int i = 0; i &lt; bricks.size(); i++)
  {
      bricks[i].setTexture(bloqueTexture);
      bricks[i].setPosition(100 + (i * 45) , 320);
      window.draw(bricks[i]);
  }
  </code></pre>