diff options
author | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-09-25 13:07:13 +0200 |
---|---|---|
committer | heavydemon21 <nielsstunnebrink1@gmail.com> | 2024-09-25 13:07:13 +0200 |
commit | 35224c07549448e919a18a463e5dec81bbabf7c6 (patch) | |
tree | 6c9dea5b449625b057511f7f052842ab3cd1d7e8 /resource-manager/resource_fabricator.h | |
parent | 765485ced528ca2f4cf644a1503b9446c5826731 (diff) |
spritesheet and image changed
Diffstat (limited to 'resource-manager/resource_fabricator.h')
-rw-r--r-- | resource-manager/resource_fabricator.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/resource-manager/resource_fabricator.h b/resource-manager/resource_fabricator.h index 3489341..2d46b00 100644 --- a/resource-manager/resource_fabricator.h +++ b/resource-manager/resource_fabricator.h @@ -2,8 +2,13 @@ +#include "Audio_asset.h" +#include "Image_asset.h" #include "resource.h" #include "constants.h" +#include "spritesheet.h" +#include <SDL_render.h> + using namespace crepe; @@ -13,8 +18,10 @@ class ResourceFactory { public: - static Resource* create_resource(const Constants::FILE_PATH& file_path); - + template<typename T> + static Resource* create_resource(const Constants::FILE_PATH& file_path){ + return new T(file_path); + } }; |