Download

Attach a Blueprint to a Skeleton Mesh using Blueprints

Hello.
I’ve got a problem with a blueprint.

I’ve created my own Character Controle from scratch using the default character from UE4 and I used the Animation Starter Kit from the Marketplace.
Everything is working just fine, but now I want to add à Flashlight in the hand of my character, the Flashlight is part of the “Horror Pack” on the Marketplace as well.
This Flashlight is a blueprint.

I’ve created a socket ont the Skeleton mesh and I did this on the construction script of the Character Blueprint

ff25a31c16e64750fddf4e8c4c9e6fcb6a46c2ce.png

Now the flashlight is here but not in the hand of the character and it’s not moving with him too.
Do you have an idea of what I did wrong ?

Thank you. :slight_smile:

Change the AttachType to “snap to target” + check if you have attached the root object of your flashlight bp + you need a socket name (Unreal Engine 4 Tutorial: Attach to Socket (english) - YouTube) + make sure that you have disabled the collision of the flashlight :slight_smile:

Go into your skeleton, and create a new socket on the hand bone, and give it a name. Now enter that socket name into the ‘In Socket Name’ on the attachment node, and change the attach type to be snap to target.

Ok sorry I make this screenshot before doing some modifications.
So I have my Socket named Flashlight on the bone “hand_l”

@fighter5347 You said “check if you have attached the root object of your flashlight bp” and I don’t know what you are talking about sorry
And where do I check about the collision ?

Thank you

PS : here is the updated BP

Capture.PNG

root object -> the one at the top that is the “root” of everything e.g on this picture the “DefaultSceneRoot” is the root object. So when you attach that, it will also attach the static mesh. Otherwise when you just attach the mesh (when it’s not a root object), everything else wont be attached.

root.jpg

collision -> in the flashlight bp click on the mesh or collision volume - in the details panel you can change the collision mode

Also make sure that you have added the flashlight bp into your level first before you attach it -> either just drag and drop it into your level or spawn it :slight_smile:

Thank you for all those details I learn a lot.
So I checked everything and it isn’t working.

I draged the BD in the scene so I’ve got two f them, the one I draged and the one spawned by the Character controller BP.
Or at least it is not following the Character

Post a pic of the component tab from the flashlight and how your attaching setup looks like -> have you done it like in the video? (should work the same when you do it in a character bp) :slight_smile: