Skip to content

Commit

Permalink
Subdirectory related amendments (#474)
Browse files Browse the repository at this point in the history
* Add ExternalData directory to CMakeLists.txt

* Move external data files to game-based subdirectory
  • Loading branch information
jerethk authored Nov 25, 2024
1 parent f063c35 commit 297918d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ if(ENABLE_TFE)
# the necessary support file directories into the build env.
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/Captions)
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/Documentation)
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/ExternalData)
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/Fonts)
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/Mods)
execute_process(COMMAND ln -sf ${CMAKE_SOURCE_DIR}/TheForceEngine/Shaders)
Expand Down Expand Up @@ -130,6 +131,7 @@ if(ENABLE_TFE)
install(DIRECTORY
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/Captions"
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/Documentation"
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/ExternalData"
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/UI_Text"
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/UI_Images"
"${CMAKE_CURRENT_SOURCE_DIR}/TheForceEngine/EditorDef"
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions TheForceEngine/TFE_ExternalData/weaponExternal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ namespace TFE_ExternalData
{
const char* programDir = TFE_Paths::getPath(PATH_PROGRAM);
char extDataFile[TFE_MAX_PATH];
sprintf(extDataFile, "%sExternalData/projectiles.json", programDir);
sprintf(extDataFile, "%sExternalData/DarkForces/projectiles.json", programDir);

TFE_System::logWrite(LOG_MSG, "EXTERNAL_DATA", "Loading projectile data");
FileStream file;
Expand Down Expand Up @@ -148,7 +148,7 @@ namespace TFE_ExternalData
{
const char* programDir = TFE_Paths::getPath(PATH_PROGRAM);
char extDataFile[TFE_MAX_PATH];
sprintf(extDataFile, "%sExternalData/effects.json", programDir);
sprintf(extDataFile, "%sExternalData/DarkForces/effects.json", programDir);

TFE_System::logWrite(LOG_MSG, "EXTERNAL_DATA", "Loading effects data");
FileStream file;
Expand Down

0 comments on commit 297918d

Please sign in to comment.