Hi all, I've created a 2.5D game and somehow when clicking to have my character move the mouse cursor registers way off center of where I initially clicked and the character then moves to that spot?
The destination in 3D space has to be on a NavMesh - if there isn't one "under" the mouse when you click, then it'll find the nearest point to it. Does your NavMesh cover the bottom portion of your image?
Hi Chris, thanks for the quick feedback. I believe my Navmesh does cover the bottom part of my screen. I've attached some more screenshots for you - perhaps this will give you a better idea of the issue?
2. I've checked all the cameras in my scene and the FOV is set to 36 on all of them. I have three custom cameras and then a MAIN and Background camera. Perhaps worth noting that I started the project as a 3D project and changed the camera to 2.5D. I think it then recreated the Background camera. - could this be an issue? Screenshots in the link below.
3. I did change this setting but issue was not resolved.
Whether you use Mesh Collider or Unity Navigation for your pathfinding, you still need to have the walkable area covered with a Trigger Collider tagged as "NavMesh" in order to recieve mouse clicks. The NavMeshes in your screenshots don't seem to have a Collider.
The NavMeshSegment prefab has all the necessary components - you don't have to use it specifically, but you can at least use it to know what your own collider needs.
Separately, I notice you're using the Demo_SceneManager asset file - I'd strongly recommend using your own set of Manager assets for creating your own game, so that they don't get overwritten when you update AC. You can do this by using the New Game Wizard (see Section 1.3 of the Manual).
Thanks Chris, much appreciated - still learning as I go but it's an amazing product you created and the support you offer is a differentiateing factor for sure!
Comments
The NavMeshSegment prefab has all the necessary components - you don't have to use it specifically, but you can at least use it to know what your own collider needs.
Separately, I notice you're using the Demo_SceneManager asset file - I'd strongly recommend using your own set of Manager assets for creating your own game, so that they don't get overwritten when you update AC. You can do this by using the New Game Wizard (see Section 1.3 of the Manual).