Welcome to TRS
Transfer case shift fork is most likely broken or a roll pin sheared off
Have to drop transfer case and have a look inside to see what failed, nothing you can do from the outside except what you already have done, manually move the shift rod
If you look for a used one you need one from a 1998-2000 Ranger or Mazda B-series 4x4 electric shift, engine or transmission doesn't matter
2001-2011 can work but have to check the size of rear flange where drive line bolts on, there were 2 sizes, I think 2.5" and 3" if memory serves
These didn't have the electric clutch inside for "shift on the fly" but since the front hubs were always Locked(Live Axle) they shouldn't need the clutch because both drive shafts were always turning at the same speed.
1997 and earlier have different front drive line connection
BW1354 is the model number for the transfer case used in Rangers after 1990 or so, but as said there were changes to driveshaft connections, so 1998-2000 should work for you
Technically you have a BW1354e for electric shift, there were also BW1354m for manual shift(shifter stick in the floor)
Info here:
https://www.therangerstation.com/tech_library/1983-2011_ford_ranger_transfer_cases.shtml
Good place to look for used parts is: car-part.com