From 52fc0ffbacb1c17d13a64436877c8cfb0067e908 Mon Sep 17 00:00:00 2001 From: IceCryptonym Date: Tue, 24 Mar 2020 20:31:31 +1000 Subject: [PATCH] Forgot to change key parameter to correct value --- src/WallpaperEngine/Core/CProject.cpp | 4 ++-- src/WallpaperEngine/FileSystem/FileSystem.cpp | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/WallpaperEngine/Core/CProject.cpp b/src/WallpaperEngine/Core/CProject.cpp index ba1940b..5073345 100644 --- a/src/WallpaperEngine/Core/CProject.cpp +++ b/src/WallpaperEngine/Core/CProject.cpp @@ -19,8 +19,8 @@ CProject* CProject::fromFile (const irr::io::path& filename) json content = json::parse (WallpaperEngine::FileSystem::loadFullFile (filename)); auto title = jsonFindRequired (&content, "title", "Project title missing"); - auto type = jsonFindRequired (&content, "title", "Project type missing"); - auto file = jsonFindRequired (&content, "title", "Project's main file missing"); + auto type = jsonFindRequired (&content, "type", "Project type missing"); + auto file = jsonFindRequired (&content, "file", "Project's main file missing"); auto general = content.find ("general"); CProject* project = new CProject ( diff --git a/src/WallpaperEngine/FileSystem/FileSystem.cpp b/src/WallpaperEngine/FileSystem/FileSystem.cpp index 0ee94a6..5011cbc 100644 --- a/src/WallpaperEngine/FileSystem/FileSystem.cpp +++ b/src/WallpaperEngine/FileSystem/FileSystem.cpp @@ -1,6 +1,8 @@ // filesystem includes #include "FileSystem.h" +#include + // engine includes #include "WallpaperEngine/Irrlicht/CContext.h" @@ -10,6 +12,7 @@ using namespace WallpaperEngine; std::string FileSystem::loadFullFile (const irr::io::path& file) { + std::cout << file.c_str() << std::endl; irr::io::IReadFile* reader = IrrlichtContext->getDevice ()->getFileSystem ()->createAndOpenFile (file); if (reader == nullptr)