Wrap calls to setgenerate...

...and drop unnecessary rpc call to getblockcount, since every simulation
starts over.
prevent hang during actor shutdown