I've always just instantiated sprites directly in the main function. Like:
int main(int argc, char **argv) {
Sprite SprPlayerWalk("Graphics/PlayerWalk.png");
Sprite SprPlayerJump("Graphics/PlayerJump.png");
Sprite SprPlayerShowingMiddleFinger("Graphics/PlayerShowingMiddleFinger.png");
while (Open()) {
...
}
return 0;
}
However, I have realised that this is... pretty dumb... Especially if you're going for a project that relies on more than 20 external files.
I've Googled for a while but I can't find ANY information about managing media...
Perhaps I'm searching for the wrong thing, that may have a huge impact on the results.
I have thought about having a class "Graphics" that stores all graphics, and "Audio" for all audio... And just make a loader class that loads everything in to their respective class. However, I'm unsure how tidy that'd really be...
So if anyone has any advice or any guides to refer me to, then I'd highly appreciate it
Thanks in advance.