x

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"

Why is SetupAttachment not working as expected?

I am trying to attach the camera boom from the third person C++ template to the character's head. I created a socket called "firstperson", and changed the code to the following:

 CameraBoom->SetupAttachment(GetMesh(), TEXT("firstperson"));

I had trouble getting it attached to anything at first, but at some point it attached to the mesh properly, but it still won't attach to the socket. Can someone please tell me what i'm doing wrong? I can't find anything on this.

Product Version: UE 4.17
Tags:
more ▼

asked Aug 31 '17 at 08:46 PM in C++ Programming

avatar image

jurplel
6 1 4 6

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

1 answer: sort voted first

I have fixed it by using AttachToComponent in BeginPlay

more ▼

answered Sep 05 '17 at 03:16 AM

avatar image

jurplel
6 1 4 6

avatar image ManWithBrisk Sep 13 '17 at 03:30 AM

Thank you very much for this post. I spent almost an hour wondering why my components were not following their mesh!

avatar image jurplel Sep 13 '17 at 03:02 PM

No problem, glad I could help!

(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