Hi, I have a problem I just can't get my head around right now. I have a ball with a base, 2 resources to be collected and two blokes to do the collecting which will move around the ball's surface. I have the blokes moving to the correct angle but, they don't pick the nearest to them. What am I missing?
Develop games in your browser. Powerful, performant & highly capable.
You have the bloke's and resource's origin points at the centre of the ball so they're actually all in the same place. They're all equal distance to each other.
So I have, thanks knew I missed something.
Maybe I should set it up to find the nearest based on image point or create a hidden object pinned to the resources and find that.
I tried an object pinned to the resource with the origin point set to the centre of itself and then tried to find the nearest to this object but, I'm getting the same results.
I thought It would be like this
1. find the position of bloke.
2. find the position of resource closest to bloke.
3. find the angle between each object.
4. rotate bloke until it's at the calculated angle.
I see the problem now, the blokes origin is in the center so anything on the ball is going to be the same distance, I need a new way of looking at this