Make entity move with entity

ok so I added a arm to the entity(player)


How do I make the arm move with the character

You can make it a child of the player entity or set the position of it at a local offset of the player entity every frame.

Yep I made both of the entities the same as the camera it only worked for the player not the arm

What issue are you having? Is the arm not rotating with the camera? Is it not moving with the player? Can you share the project link?

No lol the arm is no longer connected to the plaer want me to send the project link?

Btw this is what it loks like


Heres the project link:https://playcanvas.com/editor/scene/816114

The code for the First Person Movement is causing the issues.

In initialize, the this.camera is set to null so during the update, it creates a new camera object that is a child of the player object.

Additionally, the mouse look code (this.camera.setLocalEulerAngles(this.eulers.y, this.eulers.x, 0);) is only rotating the camera, not the player entity.

Ok so…

You want me to make it so that the player focuses to only one camera and not make another camera that is the child of the player