TransfromControls can't attach to selected objects. TransformControls move separate from selected objects

I try create simple scene with very simple setup for TransformControls but it not working as it should be.

this my code:

 this.m_TransformControls = new TransformControls(this.m_Camera,this.m_Canvas);
        EventManager.Instance.Subscribe(EventType.SELECTED,(obj: Object3D) =>
        {
            this.m_TransformControls.attach(obj);
            this.m_SceneManagementEditor.Scene.add(this.m_TransformControls);
        });

thank you in advance :smile:

Here is a simple example of TransfromControls, hopefully it will help you find the problem.
https://codepen.io/qiumeng12/pen/zYjNvGO

1 Like