From 356ec24cc20f93693cef18aa6ff165c3f1cfa299 Mon Sep 17 00:00:00 2001 From: mushgunAX Date: Mon, 9 Jan 2023 17:21:24 +0800 Subject: [PATCH] Change default pathing for binding file I/O --- Assets/Bindings.SHConfig | 51 ------------------------- SHADE_Engine/src/Input/SHInputManager.h | 5 ++- 2 files changed, 3 insertions(+), 53 deletions(-) diff --git a/Assets/Bindings.SHConfig b/Assets/Bindings.SHConfig index e0023603..573541ac 100644 --- a/Assets/Bindings.SHConfig +++ b/Assets/Bindings.SHConfig @@ -1,52 +1 @@ -4 -Horizontal -0 -0 -5 -0.2 -5 -0 -2 -39 -68 -2 -37 -65 -2 -3 -16 -1 -2 -Mouse Wheel -3 -0 -1 -0.2 -1 -0 -0 -0 -0 -0 -Mouse X -1 -0 -1 -0.2 -1 -0 -0 -0 -0 -0 -Mouse Y -2 -0 -1 -0.2 -1 -0 -0 -0 -0 0 diff --git a/SHADE_Engine/src/Input/SHInputManager.h b/SHADE_Engine/src/Input/SHInputManager.h index 30ee00e8..680035c3 100644 --- a/SHADE_Engine/src/Input/SHInputManager.h +++ b/SHADE_Engine/src/Input/SHInputManager.h @@ -14,6 +14,7 @@ #include #include #include "../../SHADE_Managed/src/SHpch.h" +#include "../../SHADE_Engine/src/Assets/SHAssetMacros.h" #include "SH_API.h" #pragma comment(lib, "xinput.lib") @@ -686,11 +687,11 @@ namespace SHADE /*------------------------------------------------------------------------*/ //Save bindings registered into a file - static void SaveBindings(std::string const& targetFile = "../../Assets/Bindings.SHConfig") noexcept; + static void SaveBindings(std::string const& targetFile = std::string(ASSET_ROOT) + "/Bindings.SHConfig") noexcept; //Load and register bindings from a file //If specified file exists, the current list of bindings will be overwritten, so save them somewhere else before loading - static void LoadBindings(std::string const& sourceFile = "../../Assets/Bindings.SHConfig") noexcept; + static void LoadBindings(std::string const& sourceFile = std::string(ASSET_ROOT) + "/Bindings.SHConfig") noexcept; /*------------------------------------------------------------------------*/ /* Binding Functions */