modify cmake to add assets to out

This commit is contained in:
2025-11-11 23:02:34 -05:00
parent 6e4d5e8202
commit 07508db546
+6
View File
@@ -23,3 +23,9 @@ FetchContent_MakeAvailable(SFML json)
add_executable(main src/main.cpp src/Entity.cpp src/Game.cpp src/MazeMap.cpp src/ResourceManager.cpp)
target_compile_features(main PRIVATE cxx_std_17)
target_link_libraries(main PRIVATE SFML::Graphics SFML::Audio nlohmann_json::nlohmann_json)
add_custom_command(TARGET main POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_directory
${CMAKE_SOURCE_DIR}/assets
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/assets
COMMENT "Copying assets to build directory")