You create your vertex array with an initial number of 6 points, but with Append you add other points instead of filling the 6 initial points. So you end up with 12 points: 6 empty + 6 of your hexagon.

So either you set an initial number of points and use operator[] to access them, or you only use Append.

By the way, your function would be much more efficient (no dynamic allocation/deallocation) with a fixed-size array of vertices allocated on the stack:

`void DrawHexagon(float X, float Y, float W, float H, sf::Color Col)`

{

float HalfWidth = W / 2;

float HalfHeight = H / 2;

sf::Vertex Hex[6] =

{

sf::Vertex(sf::Vector2f(X, Y + HalfHeight), Col),

sf::Vertex(sf::Vector2f(X + (HalfWidth / 2), Y), Col),

sf::Vertex(sf::Vector2f(X + HalfWidth + (HalfWidth / 2), Y), Col),

sf::Vertex(sf::Vector2f(X + W, Y + HalfHeight), Col),

sf::Vertex(sf::Vector2f(X + HalfWidth + (HalfWidth / 2), Y + H), Col),

sf::Vertex(sf::Vector2f(X + (HalfWidth / 2), Y + H), Col)

}

App.Draw(Hex, 6, sf::TrianglesFan);

}

sf::VertexArray is really just a std::vector<sf::Vertex>. Don't overuse it.