Improved laser code