From c0c9f494330947a8adc4990e5582d03dc9f4baa0 Mon Sep 17 00:00:00 2001 From: Garux Date: Sat, 13 Mar 2021 16:57:31 +0300 Subject: [PATCH] * common shaders deduction: fallback to .game "common_shaders_dir" param (default = "common/"), so they may be configured all at once #64 --- radiant/filterbar.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/radiant/filterbar.cpp b/radiant/filterbar.cpp index b78ee78e..86f5321c 100644 --- a/radiant/filterbar.cpp +++ b/radiant/filterbar.cpp @@ -25,7 +25,10 @@ CopiedString GetCommonShader( const char* name ){ else{ sstream.clear(); if( string_empty( g_pGameDescription->getKeyValue( "show_wads" ) ) ){ - sstream << "textures/common/" << name; + const char* commonDir = g_pGameDescription->getKeyValue( "common_shaders_dir" ); + if( string_empty( commonDir ) ) + commonDir = "common/"; + sstream << "textures/" << commonDir << name; } else{ sstream << "textures/" << name;