2
« on: August 05, 2015, 03:46:17 am »
Hi.
My problem is:
I want that when I press the space bar a RectangleShape is created and added to a list and I want to draw all the list's members.
Of course, my list is a sf::RectangleShape's list.
The list has a 10 maximum size.
Example:
I press the space bar:
list[0] = sf::RectangleShape(sf::Vector2f(100, 100));
Draw the list's members:
for (int i = 0; i < *list's size*; i++) {
window.draw(list);
}
Of course, my list is a sf::RectangleShape's list.
The list has a 10 maximum size.
The problem is in the "window.draw(list);" line.
I don't know what did I make wrong.
Please help me!
Thank You!