<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def replace_vertex_references(self, mask):
 """ Replace the vertex index references in every entity. Parameters mask : (len(self.vertices), ) int Contains new vertex indexes Alters entity.points in self.entities Replaced by mask[entity.points] """

        for entity in self.entities:
            entity.points = mask[entity.points]