Hello,
is possible to link an actor to the creature bones in blueprint or is there any way to make something like socket for creature bones in ue4?
thanks,
UE4 attach to bone
Re: UE4 attach to bone
Hello,
The way it is done with the Creature plugin is via the BP function: GetBluePrintBoneXform(FString name_in, bool world_transform, float position_slide_factor)
You give it the bone name and remember to set doWorldTransform to True. It will return you the world transform along the bone determined by the position_slide_factor. position_slide_factor allows you to "slide" along the bone.
position_slide_factor determines how far left or right the transform is placed. The default value of 0 places it
in the center of the bone, positve values places it to the right, negative to the left.
With the returned world transform, you can then set or attach any collider/external object to that transform which targets the bone of your choice.
Cheers
The way it is done with the Creature plugin is via the BP function: GetBluePrintBoneXform(FString name_in, bool world_transform, float position_slide_factor)
You give it the bone name and remember to set doWorldTransform to True. It will return you the world transform along the bone determined by the position_slide_factor. position_slide_factor allows you to "slide" along the bone.
position_slide_factor determines how far left or right the transform is placed. The default value of 0 places it
in the center of the bone, positve values places it to the right, negative to the left.
With the returned world transform, you can then set or attach any collider/external object to that transform which targets the bone of your choice.
Cheers
-
- Posts: 5
- Joined: Fri Jun 16, 2017 8:38 pm
Re: UE4 attach to bone
Thanks for breaking this down.
So if I'm understanding correctly, you are deriving the transform from the bone, but I'm not totally clear on the attachment step. Are you grabbing the transform and then setting that each frame using tick? Or is there an attachment function that I'm missing?
Any clarification would be much appreciated.
Thanks!
So if I'm understanding correctly, you are deriving the transform from the bone, but I'm not totally clear on the attachment step. Are you grabbing the transform and then setting that each frame using tick? Or is there an attachment function that I'm missing?
Any clarification would be much appreciated.
Thanks!
Re: UE4 attach to bone
Hello,
You get the bone transform, then take that value and set it to your target for each tick.
Cheers
You get the bone transform, then take that value and set it to your target for each tick.
Cheers
-
- Posts: 5
- Joined: Fri Jun 16, 2017 8:38 pm
Re: UE4 attach to bone
Gotcha, thanks for the quick response!