Remove calls to error() and FormatStateMessage() and FormatMoney() from some consensus code in main.
This is necessary because libconsensus cannot depend on util.cpp, which exposes globals among other things. Doing this before moving this consensus code out of main allows consensus/consensus.cpp to never depend on util.cpp and it removes the necessity to make FormatStateMessage() non-static to call it, temporarily, from consensus/consensus.cpp.
This also restores some error reporting that seems to have been lost, maybe while moving to use FormatStateMessage().