Connecting animated object to rig?

I am very new to all of this and have attempted to Google but I suspect I’m just not using the correct terms.

I have a rigged character and want to animate another object sliding/floating up and down the length of the characters arm. The object should maintain its position relative to the position of the arm when the arm is moved/posed. I have seen that you can parent an object to a bone but in this case the object is moving along multiple bones, so maybe that’s not what I should be looking at?

Does this make sense? Is there an easy way to accomplish this?
I’d appreciate if someone could point me in the right direction.

hi there welcome to blender , or the wonderful world of 3D animation :stuck_out_tongue:

you are on the right track for looking at “parenting” objects.
there are 2 basic points to know-

  1. parented objects can be in tree structures (like folders a<b<c )
  2. objects have a set of “local” axis of its own.

one simple way of doing it is,
make an empty (or circle, just anything that won’t show up in render)
and parent the empty to bone instead. then your animated object goes under that empty.

align the things to the same axis before moving / rotating
eg. arms pointing along Y-axis then so shall the object. (ctrl-A to apply transform to the obj)

after assigning parents,
the empty(plus its child object) follows the arm’s location and rotation.
when you need it to move up and down, simply move it along its local axis.
(at top of the viewport, change global to local)

im imagining your object is just some kind of magical object / effect floating along the arm.
if it Must actually touch the arm and collide (bounce off) with it,
then you need to set up the collision physics, which is another story.

Are you saying it needs to slide up and down, over the bending elbow?

There are two ways I can envision doing that, but I wouldn’t say either one is appropriate for somebody who is very new at this.

The first technique I can imagine is to create a curve object hooked to bones such that it represents the path of your arm (probably, with vector handles) and then use a follow path constraint targeting that curve.

You may have some issues with that, where it doesn’t really follow the arm well, especially as it crosses the elbow, because of the weights on the mesh. In that case, I might consider a live data transfer modifier of weights from an undeformed copy of the character mesh, followed by armature deformation with the same armature.

I don’t expect either of those make much sense to you right now, but they might get you started on looking things up.