Problem with pl:SetMaterial()

For some reason, it doesn’t seem to work for me. It doesn’t return an error or anything but I don’t think the player entity material is being changed.

All I’m doing is in the gamemode setting the players model and then setting it to a material. FYI the material is not the one used on the model. For testing purposes I tried models/debug/debugwhite and all other default textures, but the model insists on giving itself the texture of its origin.

Is there anything I’m doing wrong? It’s being set right after the player model was set, and called during the Gamemode Set Model bit.

Another script may be overriding the hook/setting a different model. Add a timer that sets the material after everything else…

[lua]timer.Simple( 0.1, pl.SetMaterial, pl, “material” );[/lua]

Thanks I’ll try it!

Nope, still not working :frowning:

did you try a longer delay like 1 to 3 seconds? Also where are you calling this?