I've been working on getting better with SFML. After a few simple projects which went well, I wanted to learn a vital skill. Dividing my code into seperate header files so that I don't just have a giant wall of code. I decided to try and remake Zelda II's Sword system, which I always felt was very fun to fight with.
However, I was soon stumped by this.
Unhandled exception at 0x76f415de in Zelda II Swordfight.exe: 0xC0000005: Access violation reading location 0xc5fed298.
I managed to pinpoint it down to this line.
In Graphics Handling/func_drawscreen.h/window->draw(*sprite_title_p);
If I move the initialization of the texture and conversion of it to a sprite into the same file, all works fine.
http://www.sendspace.com/file/fyiff7 There's my project. I'm using Microsoft Visual C++ 2012. I'm hoping this is just some dumb mistake on my part. If anyone could help me it would be greatly appreciated.