Use the same mesh with different entities

Is there a way to use the same mesh for more entities without copying it?

I am generating the mesh like this:

let mesh = world.exec(|loader: AssetLoaderSystemData<'_, Mesh>| {
            .generate::<(Vec<Position>, Vec<Normal>, Vec<Tangent>, Vec<TexCoord>)>(None)

end in a loop with different materials and transforms, I am creating the entities like this:


But I think the clone could be avoided somehow…

Rust prevents you from spreading your references around and lose overview over which variables are alive and what they contain. You cannot prevent the clone afaik, however this clone is cheap in Amethyst, since you do not clone the actual mesh, but only a handle to the mesh data. Think of it as cloning a pointer.