Beam particle and far end point

My bad I’m just an idiot.
I made a mistake in my code.
Thx for the answer