can't see moving vertices when object has several materials

When I add an object with more than one material and try to move all vertices with this script:

for mesh in object.meshes:
    for m_index in range(len(mesh.materials)):
        print('m = ',m_index)
        for v_index in range(mesh.getVertexArrayLength(m_index)):
            print('v = ',v_index)
            vertex = mesh.getVertex(m_index, v_index)
            print([vertex.x, vertex.y, vertex.z])

… , the terminal shows that after a sensor pulse to the script ALL vertices are moving. But the 3D view shows moving vertices of ONLY ONE material.
What am I doing wrong?

Please use code tags [noparse]


The code is not complete.

I think this is a bug (as some other problems with multi-material).

I suggest to prepare a demo file and open a Bug in GameEngine Bugtracker.

Thank you for the information!