Advertisement
illwieckz

quick&dirty nonsolid coloring

Oct 25th, 2024 (edited)
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.68 KB | None | 0 0
  1. diff --git a/src/engine/renderer/tr_shader.cpp b/src/engine/renderer/tr_shader.cpp
  2. index 5c31668ab..7f4d8149a 100644
  3. --- a/src/engine/renderer/tr_shader.cpp
  4. +++ b/src/engine/renderer/tr_shader.cpp
  5. @@ -5180,6 +5180,15 @@ static void FinishStages()
  6.             continue;
  7.         }
  8.  
  9. +       if ( stage->type == stageType_t::ST_DIFFUSEMAP || stage->type == stageType_t::ST_COLLAPSE_DIFFUSEMAP )
  10. +       {
  11. +           if ( !( ( shader.contentFlags & CONTENTS_SOLID ) || !( shader.surfaceFlags & SURF_NONSOLID ) ) )
  12. +           {
  13. +               stage->bundle[ TB_COLORMAP ].image[ 0 ] = tr.flatImage;
  14. +               stage->type = stageType_t::ST_COLORMAP;
  15. +           }
  16. +       }
  17. +
  18.         switch ( stage->type )
  19.         {
  20.             case stageType_t::ST_REFRACTIONMAP:
  21.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement