Matching object rotations

I have always had issues with Playcanvas rotations. Today Im trying to match one objects rotation with another but the rotations never match and the entity Im trying to rotate just seems to use any random rotation it chooses.

I have an object that is a child of my camera (Angle_Box). When I click on an object in the scene I want the object I clicked on (this.entity_to_rot) to match the rotation of the Angle_Box. But it doesnt. What is happening?
Ive tried, both local and global and mix and matching but I get the same unpredictable results.

this.angle_box =this.app.root.findByName("Angle_Box");// I want to match my hit_entity rotation to this entity
var box_rot =this.angle_box.getEulerAngles();
 rotationEuler.set(0,box_rot.y,0);
this.entity_to_rot.setLocalEulerAngles(rotationEuler);//Just random..doesnt match at all

Note that the Angle_Box is a child of my camera.

You are reading Euler angles in world space, then applying them in local space. You should use world for both reading and writing, if the entities have different parents.

I tried that. The rotations still didn’t match.

That is not very helpful. Not matched as in what way? Also note, that when using Euler angles, they will be calculated from quaternion and may flip 180, as it tries to get the smallest angle. Maybe you could create a small repro project to demo the issue you are facing?