-3

I am working in game project (shooter game)

I want my player to have a shoot ray show the point of impact

The Player ------------> my target

how can I approach this in untiy5 using C#

Mina Fawzy
  • 20,852
  • 17
  • 133
  • 156

1 Answers1

1

You need to do a raycast forward from the camera and check what did it hit.

When you have both points (one being the weapon/camera, second the place it hit) connect them with a line using a line renderer.

Krzysztof Bociurko
  • 4,575
  • 2
  • 26
  • 44
  • thank you for fast answer , please edit my question to remove minus – Mina Fawzy Aug 20 '15 at 11:56
  • 2
    I'm not the one who put it there. You need to write better questions, your question was not detailed enough and you didn't show that you tried to resolve the problem yourself - most people on StackOverflow don't like this. – Krzysztof Bociurko Aug 20 '15 at 12:04