better check for integer input in gold room

http://stackoverflow.com/a/5424739