Added timebased game loop and basic collision resultion.