From d2a047892ced471dabc39682be0d03d03ceb3969 Mon Sep 17 00:00:00 2001 From: Xavier Mitault Date: Wed, 1 Nov 2023 12:45:10 +0000 Subject: [PATCH] GAME: Fix condition --- src/Game/ResourcesManager.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Game/ResourcesManager.hpp b/src/Game/ResourcesManager.hpp index 847126fa..a00b163f 100644 --- a/src/Game/ResourcesManager.hpp +++ b/src/Game/ResourcesManager.hpp @@ -6,7 +6,7 @@ #include "ResourcesManager.hpp" #include "boost/filesystem.hpp" -enum class JsonType { +enum class JsonType : std::size_t { DEFAULT_PLAYER = 0, DEFAULT_ENEMY, TERMINATORBOSS, @@ -27,7 +27,7 @@ class ResourcesManager { public: static std::string getPathByJsonType(JsonType type) { - if (paths.size() >= static_cast(type)) { + if (paths.size() <= static_cast(type)) { return ""; } return ResourcesManager::convertPath(paths[static_cast(type)]);