Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Elo01

Pages: [1]
1
Graphics / Shape.Rectangle() not working?
« on: August 10, 2009, 07:41:21 pm »
Alright, I guess I'm just using the function the wrong way - Anyway, here's the problem (using SFML 1.5 if that matters):

Code: [Select]
sf::Shape test1 = sf::Shape::Rectangle(200, 200, 400, 400, sf::Color(222, 222, 222));
The above code works just fine and draws a rect as expected, however
Code: [Select]
sf::Shape test2;
test2.Rectangle(200, 200, 400, 400, sf::Color(222, 222, 222));

doesn't seem to work (not drawing anything when calling RenderWindow.Draw()).
The weird thing is, GetPosition() still returns the right coordinates for the 2nd code.


Am i doing something wrong?

Edit: Just realised its a static function and won't work that way, nevermind this thread :/

Pages: [1]