Hello. I've encountered a strange problem while compiling my little test program, which was a try to create universal in-game window class, with text and buttons and stuff like that. So I created my class, inherited it from sf::Drawable, overrode virtual function "draw()" and tried to draw my window. Then, I've got this:
http://puu.sh/eGGu3/50b273c438.png"Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one calling convention with a function pointer declared with a different calling convention."
I searched for this error, and everyone who had the same thing was compiling SFML for themselves, from the source (using CMake and wrong calling conventions). I didn't do it, I just downloaded it from the official site, so I wonder if anyone have the same problem.
What's more, when I changed project to SFML 2.1, it built just fine. So maybe the official version is a little broken?
Maybe I haven't changed something when updating 2.1 to 2.2, so I just asking, is anyone have similar problem?
class okno : public sf::Drawable
{
//(...)
virtual void draw(sf::RenderTarget& target, sf::RenderStates states) const
{
target.draw(ramka);
target.draw(tekst);
}
//then "window.draw(okno) gives the exception mentioned before"
};