Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Root component not following child mesh.


I'm having quite problem with player character actor. I have components in blueprint configured like below:


|| PlayerMesh (child of root)

|| SphereMesh (child of root)

|| || Camera (child of Sphere)

When I set velocity to the PlayerMesh I expected movement of whole character but I can see my PlayerMesh floating away. I can use "SetLocation" to move RootScene to the place where the PlayerMesh is, but I suppose it shouldn't work like that? Am I missing something here?

Product Version: UE 4.10
more ▼

asked Mar 03 '16 at 11:35 AM in Blueprint Scripting

avatar image

3 1 2 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

The location of the root scene does not change unless you specifically change the actor location. Everything inside the actor with physics enabled will only update it's own position and all it's children, the root of the actor will stay stationary, as will all other components in the actor.
So if you have two physics enabled objects in an actor you should regard them as two seperate entities that have their own location. In your specific case, you probably want to attach the camera to the playermesh (camera should be a child of playermesh). The the camera will move along with the playermesh.

Another thing: if you want the actor to move along with something that has physics enabled, then that physics enabled component should be the root of the actor (delete the root scene). So if you make the playermesh the root component of the actor, then everything else will move with it.

more ▼

answered Mar 03 '16 at 12:07 PM

avatar image

391 36 36 80

avatar image hagier Mar 03 '16 at 01:05 PM

Thank you very much for answer. This explains a lot.

I want to camera move independently of PlayerMesh or with it (as player choose) so I figured out to add a new scene component as root and change parent of Sphere (which controls rotation around the object). But then everything went wrong. :)

Your answer made me understand how the parenthood here works and I couldn't figure it on my own without help. So thank you very much again.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question