summaryrefslogtreecommitdiff
path: root/utils/vbsp/materialsub.h
diff options
context:
space:
mode:
authorFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
committerFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
commit3bf9df6b2785fa6d951086978a3e66f49427166a (patch)
tree2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /utils/vbsp/materialsub.h
downloadarchived-source-engine-2018-hl2-src-master.tar.xz
archived-source-engine-2018-hl2-src-master.zip
Diffstat (limited to 'utils/vbsp/materialsub.h')
-rw-r--r--utils/vbsp/materialsub.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/utils/vbsp/materialsub.h b/utils/vbsp/materialsub.h
new file mode 100644
index 0000000..ce6cac4
--- /dev/null
+++ b/utils/vbsp/materialsub.h
@@ -0,0 +1,25 @@
+//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose: This file loads a KeyValues file containing material name mappings.
+// When the bsp is compiled, all materials listed in the file will
+// be replaced by the second material in the pair.
+//
+//=============================================================================
+
+#ifndef MATERIALSUB_H
+#define MATERIALSUB_H
+#ifdef _WIN32
+#pragma once
+#endif
+
+extern bool g_ReplaceMaterials;
+
+// Setup / Cleanup
+void LoadMaterialReplacementKeys( const char *gamedir, const char *mapname );
+void DeleteMaterialReplacementKeys( void );
+
+// Takes a material name and returns it's replacement, if there is one.
+// If there isn't a replacement, it returns the original.
+const char* ReplaceMaterialName( const char *name );
+
+#endif // MATERIALSUB_H \ No newline at end of file