Changed temperature to double and make it a bit random.