I've replaced the motor in mine twice now, it's not cheap and I did the work myself.
A motor from the junkyard was $2100 the first time. The second time I bought a whole parts vehicle from the insurance auction, also about $2000.
The engine itself (shortblock + heads) is identical to the engine in the automatic Mach 1 and the Maurader. The manual Mach 1s have a different forged crank shaft with 8 bolts instead of 6 for the flywheel. This may help you in a search for a replacement engine. Look at car-part.com copart.com or iaai.com for engine sources.
From the "made a lot of noise" comment, the most likely failure is the timing chain guides, which would lead to piston to valve contact on at least one side. Only way to know for sure what happened is to start pulling it apart.
Another potential issue with these trucks are the transmissions and the shifters. The 5w55x series have an issue with the servos wearing in the bores causing the trans to slip out of gear, this extends to the Explorers as well. The shifter has a plastic piece that can break leaving you stuck in park, or solenoid that unlocks the shifter when the brake is pressed can quit working. Ebay sellers want a premium for the shifter assembly.
Given the age of these trucks and their value, you might be best off parting it out and putting the money towards something else. I can't make that decision for you tho, I rebuilt my own as a labor of love on an '03 with 70k miles.