So when making a 2D game there is a common pattern of creating objects and setting the sprites for each object. Some objects have many sprites, some have only 1.
There are 2 obvious ways to handle this.
The problem with this approach seems to be that you must then create unique interfaces for each class to pass it the sprite(s), since each may use an arbitrary number of sprites.
Doing this allows you to extend a basic sprite class and save yourself time by only having one sprite setter function to write and be inherited by all children.
So my question is just which is better and why?
To answer my own question it is better to create some sort of sprite manager that knows about all the sprites.
The problem with sending an object the tools it needs to load textures is you may end up loading the same texture multiple times if you have multiple instances of your object.