# GE: Ray help for FPS

Hi, I am making a mini FPS game to teach myself about rays.

As of now I have a ray from my player, when the enemy (cube) is within the ray and the mouse is clicked, the player sends a message to the cube telling it to die, this works but it’s not what I want. I made a HUD scene with crosshairs, ideally I want the crosshairs to cast a ray so only objects in the crosshair can ‘die’ instead of in the ray of the player- how can I do this (I already tried parenting)? Please look at the blend file as I use my custom way of turning using the mouse and WSAD. Thanks in advance for any help.

Let the Camera cast the Ray.

But will that be the size of the crosshairs? And thanks.

If you use one Ray it will always be the Size of a Point. Rays do not have a Diameter: For that you would have to use a Radar, that would suit the Case perfectly. However, the Logic is heavier and in the End it might make little Difference. If your Crosshair is a Circle, then it might make Sense, but if it is indeed a Cross, then a Ray would be enough. (If the Weapon is a Shotgun, however, you really have to take use Radar. )

Thanks C.A.ligari, so, how do I make this ‘point’ bigger/smaller? Thanks for the help

EDIT: I can’t get the camera to work using the ray - I don’t know why :(.

As said, I at least don’t think the Point can be resized. If someone outthere knows that and how it is possible, I hope they show up here and prove me wrong, but from what I know a Ray is just a Line, a mere Line, no Cylinder.
And I guess when you let the Gun or the Player cast the Ray, you probably cast it on the Y (or X) Axis. However, in Case of a Camera the Direction which the Camera is looking is always the Z-Axis (as a Camera with 0,0,0-Rotation points down as well).

Removed video, Monster helped (thank you!).

apply scale to all parents!

Ah thanks Monster

Im still having troubles, now I have this setup,