Hey, I can see why this is a bit tricky. This functionality should probably exist as a function in the base toolkit. I have made such a function now that does what you want:
This will not show up in the ability bar until the next time UpdateInitiativeBar is called in the TurnManager, so if you run the above function on the active unit and want it to show up immediately, make sure to call that function straight after.