Cross Platform Sleep

Changed to a sleep implementation which is described in the c++ 11
standard set