Changing material / texture via python?

Hi,

I need to change the material or more specifically the texture of objects in realtime. Does anyone know how?

Thanks

1/1 credit(s)

lol i asked that same question a little while ago. I needed a character to switch shirts. the best i came up with was to make the shirt a very thin object and put it over his skin… gay i know but better than having nothing

The only thing I could think of is to make another mesh with the different texture already applied. Place it in another layer and use the “change mesh” option under the edit object (I think?) actuator. I’m not sure if it’s called edit object… its the same one you use for “end object”, I know that.

Hope that helps. It’s hard to think of any other “work-around’s” unless we know exactly what your trying to accomplish in your game.