From 46410206ad0f37a77d37aac158ff531e96579c3f Mon Sep 17 00:00:00 2001 From: kaetemi Date: Tue, 5 Jan 2021 23:13:34 +0800 Subject: [PATCH] Weld borders again after elevation, for bindings --- .../build_gamedata/processes/zone/2_build.py | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/nel/tools/build_gamedata/processes/zone/2_build.py b/nel/tools/build_gamedata/processes/zone/2_build.py index cb9287c36..6dca1c0d5 100755 --- a/nel/tools/build_gamedata/processes/zone/2_build.py +++ b/nel/tools/build_gamedata/processes/zone/2_build.py @@ -145,12 +145,27 @@ else: files = findFiles(log, ExportBuildDirectory + "/" + ZoneWeldBuildDirectory, "", ".zonenhw") for file in files: sourceFile = ExportBuildDirectory + "/" + ZoneWeldBuildDirectory + "/" + file - destFile = ExportBuildDirectory + "/" + ZoneWeldBuildDirectory + "/" + os.path.basename(file)[0:-len(".zonenhw")] + ".zonew" + destFile = ExportBuildDirectory + "/" + ZoneWeldBuildDirectory + "/" + os.path.basename(file)[0:-len(".zonenhw")] + ".zone" if needUpdateLogRemoveDest(log, sourceFile, destFile): callParallelProcess([ ZoneElevation, sourceFile, destFile, "--land", land, "--heightmap", heightMap1, "--zfactor", LigoExportZFactor1, "--heightmap2", heightMap2, "--zfactor2", LigoExportZFactor2 ]) flushParallelProcesses() printLog(log, "") +printLog(log, ">>> Re-weld zone with heightmap <<<") +if ZoneWelder == "": + toolLogFail(log, ZoneWelderTool, ToolSuffix) +elif ExecTimeout == "": + toolLogFail(log, ExecTimeoutTool, ToolSuffix) +else: + mkPath(log, ExportBuildDirectory + "/" + ZoneWeldBuildDirectory) + files = findFiles(log, ExportBuildDirectory + "/" + ZoneWeldBuildDirectory, "", ".zone") + for file in files: + sourceFile = ExportBuildDirectory + "/" + ZoneWeldBuildDirectory + "/" + file + destFile = ExportBuildDirectory + "/" + ZoneWeldBuildDirectory + "/" + os.path.basename(file)[0:-len(".zone")] + ".zonew" + if needUpdateLogRemoveDest(log, sourceFile, destFile): + subprocess.call([ ExecTimeout, str(ZoneBuildWeldTimeout), ZoneWelder, sourceFile, destFile ]) +printLog(log, "") + log.close()