def execute(self, context):
ob = context.object
if self.direction and ob is not None:
verts = bmesh.from_edit_mesh(ob.data).verts
cur_verts = from_string(eval("ob.shifter_{}_verts".format(self.direction)))
removed = 0
for v in verts:
if v.select and v.index in cur_verts:
cur_verts.remove(v.index)
removed += 1
exec("ob.shifter_{}_verts = to_string(list(cur_verts))".format(self.direction))
self.report({"INFO"}, "Shifter: Removed {} Vertices".format(removed))
return {"FINISHED"}
评论列表
文章目录