From d10ae36c64123855eb828b7e2c19c6b405f0883a Mon Sep 17 00:00:00 2001 From: Emma Miler <27428383+emma-miler@users.noreply.github.com> Date: Thu, 3 Feb 2022 00:16:51 +0100 Subject: Fix pdef custom path (#64) --- NorthstarDedicatedTest/pdef.cpp | 2 ++ NorthstarDedicatedTest/pdef.h | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'NorthstarDedicatedTest') diff --git a/NorthstarDedicatedTest/pdef.cpp b/NorthstarDedicatedTest/pdef.cpp index 83a31db0..20b4bea5 100644 --- a/NorthstarDedicatedTest/pdef.cpp +++ b/NorthstarDedicatedTest/pdef.cpp @@ -11,6 +11,8 @@ void ModManager::BuildPdef() { spdlog::info("Building persistent_player_data_version_231.pdef..."); + fs::path MOD_PDEF_PATH = fs::path(GetCompiledAssetsPath() / MOD_PDEF_SUFFIX); + fs::remove(MOD_PDEF_PATH); std::string pdef = ReadVPKOriginalFile(VPK_PDEF_PATH); diff --git a/NorthstarDedicatedTest/pdef.h b/NorthstarDedicatedTest/pdef.h index ad85e372..a6bffbe4 100644 --- a/NorthstarDedicatedTest/pdef.h +++ b/NorthstarDedicatedTest/pdef.h @@ -1,4 +1,4 @@ #pragma once -const fs::path MOD_PDEF_PATH = GetCompiledAssetsPath() / "cfg/server/persistent_player_data_version_231.pdef"; +const fs::path MOD_PDEF_SUFFIX = "cfg/server/persistent_player_data_version_231.pdef"; const char* VPK_PDEF_PATH = "cfg/server/persistent_player_data_version_231.pdef"; \ No newline at end of file -- cgit v1.2.3