The rules are not clear if shooting at the end of a turn is mandatory or optional. Do I have to shoot even if I know that the laser is going to "kill" one of my own pieces?As answered, it is mandatory to shoot it. If you don't want something of yours to die, you need to think ahead to that. It's not as uncommon for both sides to accidentally miscalculate something and kill of their own pieces, or even their own pharaoh!
Furthermore, this is not a game "physical alignments", or if the laser misses because it was crooked, you need to draw it out anyways and follow its correct path. So the path of the laser beam also serves as a guide.