Welcome to the forum. Sorry, I just found your thread and hope you haven't been ripped off. Sounds like a problem with the Electronic Throttle Control (ETC).....not the whole engine. I'd recommend you don't bite on the new engine as, if it was running fine when it lost power, it for sure isn't the entire engine. Besides, the SRT engines are nearly bulletproof unless you run it out of oil.
Bottom line, find a REAL mechanic that knows Hemi's and have it properly diagnosed BEFORE you commit to a new engine. This does not sound like a serious problem. There are four major components to the ETC. They are the Front Control Module (FCM), the Throttle Body (TB), the Throttle Position Sensor (TPS) and the Powertrain Control Module (PCM). From your description, the problem sounds like it MAY Be one of these components and/or the wiring/plugs between them. If you can get hold of the Diagnostic Trouble Codes (DTC), post them here and we'll try to help. There will for sure be active DTC's and, FYI, they will be alph-numeric five digit codes, probably beginning with either a P (which means something in the Powertrain) or U (which means something to do with Communication between components), and then followed by 4 numbers.
Examples: P0121 indicates, "Throttle Position Sensor 1 Performance"
U0141 indicates, "Lost Communication with Front Control Module"
Again, hopefully you haven't already committed to a new engine. Let us know what you find out.