Simulator and other fixes