Quick Jump
Accessing a material.
mesh_index = 0 mesh = obj.getMesh(mesh_index) material_num_on_mesh =0 while mesh != None: for mat in mesh.materials: if not hasattr(mat, "getMaterialIndex"): return # material to operate on a_material = mat mesh_index += 1 mesh = obj.getMesh(mesh_index)
shader = material.getShader() if shader != None: #do stuff
import GameLogic
...
material.setBlending(GameLogic.BL_ONE, GameLogic.BL_ONE)