You don't need to worry about quaternions. If you want to calculate everything out with matrices... well, you could do that, but it would be a waste of time!
The solution is this:
xmovement=dist*(cos(x)*sin(y)*cos(z)+sin(x)*sin(z))
ymovement=dist*(cos(x)*sin(y)*sin(z)-sin(x)*cos(z))
zmovement=dist*(cos(x)*cos(y))
You get that result by rotating first around the x axis, then the y axis, then the z axis, using rotation matrices. Then you multiply that by a forward column matrix/vector: [[0][0][1]].
However... I think thats a waste of time. What I usually do if I need to do what you're talking about, is add a limb to the object, hide it, and offset it by 0,0,1. Then, you take the limb position minus the object position, and multiply that vector by dist - you get the same results as in the above equations, and Its probably faster (uhh, actually it probably doesn't make much of a difference... I guess I'm not too sure).
[edit]
errm, It's a waste of time to use those equations if you have to multiply everything out yourself. Uhh... but I guess since you wouldn't have to derive anything, it isn't. Do whatever you wan't I guess, either solution workx xD