override public SceneObject Duplicate() { DMeshSO copy = new DMeshSO(); DMesh3 copyMesh = new DMesh3(mesh); copy.Create(copyMesh, this.GetAssignedSOMaterial()); copy.SetLocalFrame( this.GetLocalFrame(CoordSpace.ObjectCoords), CoordSpace.ObjectCoords); copy.SetLocalScale(this.GetLocalScale()); return(copy); }
/// <summary> /// called internally by Duplicate() and DuplicateSubtype(), /// override to add things you want to duplicate /// </summary> protected virtual void duplicate_to(DMeshSO copy) { DMesh3 copyMesh = new DMesh3(mesh); copy.Create(copyMesh, this.GetAssignedSOMaterial()); copy.SetLocalFrame( this.GetLocalFrame(CoordSpace.ObjectCoords), CoordSpace.ObjectCoords); copy.SetLocalScale(this.GetLocalScale()); copy.enable_shadows = this.enable_shadows; copy.enable_spatial = this.enable_spatial; }