How to change socket-locations at runtime

Hi,

I want to implement a system, where the player can move the arms of his character very freely, either via mouse commands or via a Razer Hydra, a Wiimote or similar devices. Think of it like the movement in Octodad without the whole ragdollyness.
For this I want to change the local transformation and rotation of several sockets of a SkeletalMeshComponent at runtime.
I tried doing this via

Mesh->GetSocketByName("socketName")->RelativeLocation = FVector(x,y,z);

but since GetSocketByName() returns a const value, I can only read it, not change it.
Also i tried attachig another Mesh to the socket I want to move and then move this, but this only moves the new Mesh and I haven’t found a way to attach a socket to the Mesh, so it will move together with it.

Does anybody have an idea, how to solve this?

Thanks, Asgatoril

Not sure about socket changing, but you can definitely move the limbs using IK or FABRIK solvers. FABRIK can handle long chains bones in limbs. It is likely you will need bones either way due to skin binding.

See LeapMotion Plugin for an example of a rigged character setup (available in content folder). Or see the Hydra Plugin thread for a discussion about how to implement Hand IK