I am trying to create a "wander" action that will make my NPC walk to a random position.
The catch is that the NPC should only go positions inside of a collider.
I have a huge Sphere that has a collider on it now I only want my NPC to go to positions that are inside that Sphere collider.
My question is how do i find a random position inside of a colider?
So after testing i am unable to use colliders because the sphere is too big here is an image of my gameobject:
As you can see from the image I have a huge sphere that my NPC's will have to stay inside when wandering
In order to use the
Collider.ClosestPoint() the collider has to be a Box, sphere or a mesh collider with a convex.
Sadly this is not feasible for me because the sphere should not collide with other objects.
So my question is how do I find a point inside this gameobject?