How do i get crosshair to aim?


#1

so im making a simplle fps game and i was wondering how i can make the crosshair aim and aim out


#2

if its a simple FPS game, i suggest just using a 2d element image centered.

For the UI:

  1. create a 2d screen
  2. create an image element
  3. center the image element
  4. add crosshair texture.

your mouse-look should handle the movement, this project will show how:
https://playcanvas.com/project/405842/overview/tutorial-fps-movement

There are a lot of ways but from here on out, you should assume that we need a lot more information before help can be given. Your best bet is to link to a TEST project with the current problem being faced, so the team and forum members can get back to you with a solution.

The test project should be simple and only contain code about your current problem ( cross hair issue)


#3

If you are interested in not only installing a crosshair, but also shooting from the first person, then you can take a lesson from Unity and transfer the logic in your project. I hope links to third-party sources are allowed here. :sweat_smile:


#4

hey guys thnx for all the help and support you guys have been giving me I really appreciate it


#5

ssadly it hasnt helped im looking to actually make a gun shot and aim