Going to redo assets.
This commit is contained in:
15
tools/assetstool/header.py
Normal file
15
tools/assetstool/header.py
Normal file
@@ -0,0 +1,15 @@
|
||||
import os
|
||||
|
||||
def setOutputDir(outputDir):
|
||||
global OUTPUT_DIR
|
||||
OUTPUT_DIR = outputDir
|
||||
|
||||
def getOutputDir():
|
||||
return OUTPUT_DIR
|
||||
|
||||
def getHeaderInclude(headerPath):
|
||||
outputDir = getOutputDir()
|
||||
relPath = os.path.relpath(headerPath, outputDir)
|
||||
path = relPath.replace('\\', '/') # Use forward slashes for includes
|
||||
print(f" Including header: {path}")
|
||||
return f'#include "{path}"'
|
Reference in New Issue
Block a user