Browse Source

Prevents overwriting existing .torsion files.

OTHGMars 4 years ago
parent
commit
86c302c42e
1 changed files with 3 additions and 1 deletions
  1. 3 1
      Tools/CMake/torque3d.cmake

+ 3 - 1
Tools/CMake/torque3d.cmake

@@ -645,7 +645,9 @@ else()
   endif()
 endif()
 
-CONFIGURE_FILE("${cmakeDir}/template.torsion.in" "${projectOutDir}/${PROJECT_NAME}.torsion")
+if(NOT EXISTS "${projectOutDir}/${PROJECT_NAME}.torsion")
+    CONFIGURE_FILE("${cmakeDir}/template.torsion.in" "${projectOutDir}/${PROJECT_NAME}.torsion")
+endif()
 if(EXISTS "${CMAKE_SOURCE_DIR}/Templates/${TORQUE_TEMPLATE}/game/main.tscript.in")
     CONFIGURE_FILE("${CMAKE_SOURCE_DIR}/Templates/${TORQUE_TEMPLATE}/game/main.tscript.in" "${projectOutDir}/main.${TORQUE_SCRIPT_EXTENSION}")
 else()