View Single Post
06/14/22, 02:44 PM   #13
Valve
 
Valve's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2017
Posts: 23
Originally Posted by Baertram View Post
RedirectTexture normally works fine (and Masteroshi also said he exactly uses this at his linked Minimap patch?) BUT you cannot change the same texture more than once without logging off (it often simply shows the cached one then!), so often you need to close the client and delete the file live/shader_cache.cooked as it caches texture files.

Next login will take a bit longer due to the new build caches. But redirecttexture should work for the next changed textures properly again then. Sometimes changing from textureA to textureB and back to textureA also works, but trying a new textureC doesn't without that shader_cache.cooked delete.
Yeah, I'm not sure about this because I deleted the shade cache after closing the game and loaded back in.

Maybe I was doing something wrong but I was able to use RedirectTexture on other textures without issue

I've currently got it working with a colour picker in LAM2 and editing the colour values on those globals:


This does give more freedom since it can be any colour the user chooses. However, I didn't really want to edit the global table properties because I don't know if/how this will change in the future

I think it should be okay though, it's not as crazy as overriding a function so...

Edit:

I wanted to add that I did add the textures to a guild note and then did the RedirectTexture. They were redirected as expected but the area pin on the map was unaffected. So it either means the map uses a different texture (I wasn't able to find anything when I searched) or the area is built up in a different way

Last edited by Valve : 06/14/22 at 03:08 PM.
  Reply With Quote