@ -51,10 +51,10 @@ public class GameState
// TODO FIXME This is wrong for brush model entities
// TODO FIXME This is wrong for brush model entities
uq . CurrentStyle . SetupWorldModelRenderer ( mr ) ; // TODO FIXME this currently leaks Materials
uq . CurrentStyle . SetupWorldModelRenderer ( mr ) ; // TODO FIXME this currently leaks Materials
uint texNum = surfaceMesh . Texture . Texture Num;
uint texNum = surfaceMesh . TextureNum ;
if ( uq . GameAssets . TryGetTexture ( texNum , out var texture ) )
if ( uq . GameAssets . TryGetTexture ( texNum , out var texture ) )
{
{
uint fbNum = surfaceMesh . Texture . FullBrightNum ;
uint fbNum = surfaceMesh . FullBrightNum ;
uq . GameAssets . TryGetTexture ( fbNum , out var fullBright ) ;
uq . GameAssets . TryGetTexture ( fbNum , out var fullBright ) ;
uq . CurrentStyle . SetWorldModelTextures ( mr . material , texture , fullBright , null ) ;
uq . CurrentStyle . SetWorldModelTextures ( mr . material , texture , fullBright , null ) ;