Hello I made a code that there is Entity loaded on ar, and I placed cube to position which is SIMD3 what I want is that moving entity loaded on ar to move to the location where cube is located.
how I did is
self.modelentity2!.move(to: Transform(scale: simd_make_float3(1, 1, 1),
rotation: (anchorEntity.transform.rotation),
translation: newTranslation),
relativeTo: nil,
duration: 2,
timingFunction: .linear)
self.modelentity2 is entity that I loaded and anchorEntity is that I place when user tap
modelentity2 is moving very well to anchorEntity but the problem is that modelentity2 should face toward anchorEntity but it looks rotating randomly or not rotating at all. how can I move entity face to anchorEntity ?