Walking up stairs with IK and master bone

Hi,
Searching for tips on how to solve this.
I’ve created a rig that I can move around using a master bone.

The problem is: walking up on stairs.
When moving the master bone in z axis the whole rig moves and I have to reposition the feet in the exact location which creates this wiggly looking walk.

I need master bone controlling the whole rig on x and y axis and then a master bone controlling everything except the feet.

Is this possible or do you wonderful people have any tip on how you solve this?

I tried making an animation like this and it looked alright.

So the problem you run into when moving the root bone in the z axis is that all bones (including IK bones) move. To fix this you can use the 3d cursor to snap the bones (wm.call_menu VIEW3D_MT_snap in the 3d view, I forgot the default key). I bound that menu to right click in the 3d view and if you want to you can set keybindings for the commands in it by right clicking and adding shortcuts.

First you move the right foot to the next stair step, then do Cursor to Selected. After that you move the root (and the other foot) to the next stair step. This will cause the right foot to move up, so when the root has stopped moving (left foot is planted on the step) select the right foot and do Selection to Cursor, then insert a keyframe. This will counteract the animation done by the root and make it look like the foot is still (when it is actually moving the opposite direction of the root). Repeat this for the other foot and it should look fine. After the first step the root will move every step since you’re shifting your weight forwards.

One other thing to keep in mind is that when you ascend or descend stairs you start by taking one step and after that you lift the foot over the step you’re currently on which means that you take two steps. If you do this in one animation you can’t use a cyclic modifier so you will have to copy paste the loop you make when you take two whole steps.

Constrain the IK foot controls to unparented emptys with copy transforms constraints. Animate the walk up the stairs with the emptys working your rig like a rod puppet. Then you can also animate the motion\root bone ascending in line with the rig the whole time as you wish. The feet will stay locked in place. Next bake the animation into the Foot rig Ik controls with these settings…Frame Step 1…Only selected…Visual keying…Clear Constraints…Overwrite Current Action. This method is the most commonly used one I know for these sorts of situation.
Should add, probably best to bake the root bone animation along with the feet. Whole thing needs to be solidly baked on each frame to avoid slides and wobbles.

Toka is right, the feet must not be children of the hip bone, so you can move the two independently.