Rear Shimano Acera derailleur skips chain ring after replacing cable
An impact hard enough to bend the hanger is likely to have also distorted the derailleur.

For each index of the shifter pulling a consistent length of cable, the derailleur normally moves a certain distance along a path angled to be similar to the cone angle of the cassette, that distance corresponding to an axial (sideways) distance which matches the cassette spacing.

If the derailleur is deformed between the mounting bolt and the parallel plates, the angled path will be flatter, meaning the same movement along the hypotenuse will be a larger axial movement. There is a tolerance designed into the widths of the sprockets, chain and cassette gaps, so when you shift far enough from the point where you indexed the gears, the total excess movement from the flattened path will exceed the tolerance.

If the derailleur's inner plate is bent such that it's shorter than the outer plate, the distance moved along the angled path will be inconsistent, but the impact on shifting will be more extreme in the easier gears regardless of which gear you used when indexing.