1998 4WD shift control will be the same as your '99
Electric shift control module is also know as "4X4 module"(on the right in drawing below)
Relays you hear are in there, one turns shift motor Clockwise(CW), the other counter clockwise(CCW)
GEM controls most of the electrics in the truck so is also part of the 4WD system(on the left in drawing)
These are both behind the radio in the dash.
If you look at the shift motor at the bottom you will see A, B, C, and D contacts.
When the shift motor turns these contacts move and are connected and disconnected, for example, if A is connected, but B, C and D are not, then GEM knows transfer case is in 4hi, another combination means 2hi, another 4lo.
And these contacts also run the dash lights, i.e. if you select 4hi, shift motor moves, if pattern matches 4hi then 4hi light comes on, if pattern doesn't match then light will flash indicating a problem.
Electric Clutch is the clutch in the transfer case.
Go here and get the wiring diagram for '98 4WD, post #4:
http://www.therangerstation.com/forums/showthread.php?t=162915