def update_serialized_material(self, data):
        """ Internal method to update a material from a given serialized material """
        name = data[0]

        for i, material in enumerate(Globals.render.find_all_materials()):
            if self._get_serialized_material_name(material, i) == name:
                material.set_base_color(Vec4(float(data[1]), float(data[2]), float(data[3]), 1.0))
                material.set_roughness(float(data[4]))
                material.set_refractive_index(float(data[5]))
                material.set_metallic(float(data[6]))
                material.set_emission(Vec4(
                    float(data[7]),
                    float(data[8]),
                    float(data[9]),
                    float(data[10]),
                ))

        RenderState.clear_cache()
 Internal method to update a material from a given serialized material 
metadrive/render_pipeline/rpcore/render_pipeline.py