Firstly, thank you for this great course! I’ve made about 4 smaller games and this is the perfect level for me to realise that I know more than I thought but still have a lot of exciting things to learn.
Snip below shows where I have the box collider set up, however in-game it doesn’t trigger from clicks anywhere except just around the unit’s head. It isn’t offset, as the collider also doesn’t register clicks above or either side of the head, so it seems like only a small part of the collider actually registers clicks and I am not sure why.
So everything else is working fine (I’ve finished the next three lectures in case it fixed my issue).
It looks like you’re using Unity 2022.2 (I don’t believe previous versions have the Provides Contacts and Layer Overrides…
Make sure that your Layer Overrides aren’t conflicting with the Units layer.
Make sure you’re testing for the Units layer in your code
Thanks for your reply! I’m running into a few (predictable, my mistake) issues so will restart the course with Unity 2022.1. Is it best to use 2022.1.24 (the last 2022.1 update)?
Maybe you have something blocking the raycast? Can you move the camera and click? It only detects the head regardless of camera position?
Maybe you have a Floor collider with an invisible mesh at head height
Sorry for the delay. I had to download 2022.2.2f1, as I find that opening projects in the same versions works best…
This one stumped me for a few moments, because the usual suspect is transparent frames on UI, but in this case, it’s a collider hiding on the model.
There is a capsule collider on the Astronaut Rig of the Unit. We won’t need it for anything in the course, it’s probably an artifact from whatever asset you got the rig. Delete this collider, and everything should work fine.