>>323686
Aight. I know fuckall of unity so I'm gonna do a few guesses. I'\m guessing the MoveTo class is the pony.
>in-code comments
You can get the pony to not change tasks by separating the thinking and the acting step out of the Think() function. You already have a 'task' variable. Only change it from idle to something else, and have the tasks turn back to idle mode when said task is done. You can then still interrupt tasks irrespective of the task at hand, afterwards, but if you limit this to emergencies, they should generally finish a task before picking up a second one.
>-path to target (sensibly made, not my hack)
One thing that might slip you up is that a Transform is not a location; it is a function (mathematical, not c#-like) that changes the pony from the current to the new position (instantly). You can also think of it as an arrow from (0,0) in the direction and of the length the pony has to travel in. 'goal' as such might be easily confused with location of the goalObject
If you return a GameObject rather then a boolean from your FindClosest function rather then a boolean, this would allow you to work with multiple objects at once and you don't necessarily need to change your goal (variable). Believe it or not but your actual moving code is fair enough. What you are missing as far as i can see is object avoidance. This is something that is still being studied to find out the best way to do that.
One way one can do this is by using bounding boxes around objects where, as long as you are outside the bounding box, you are guaranteed to not touch the object (read: not touching it enough to be a problem; sometimes some clipping may be acceptable). Next, you keep out of those boxes.
You could either check out whether you are actually inside such a box, and move out if this is the case (this works fairly well in situations where players control the moving object), but in this case, you may want to do some planning a-priory. You need a way to find out whether any objects bounding boxes cross the direct path between you and your target. If it does, change your approach to the side of the closest object crossing this path.Once you have reached the end of the path, repeat above until you can naively path to the target.
You may realise that this might be a problem when you have multiple ponies moving around you dont want to intersect. I'm sure you dont want unicorn twilight in the exact same place as a random purple pegasus. In that case you probably want to re-calculate the paths to the target every time, at least for the objects that actually moved.
>-run a function when a path is completed
You already have a function that should tell you that you are at the end of a path. You can execute this in your think loop before you are going to shuffle destinations around. You can then execute whatever function you want in the space where you have the 'return true' statement.
If you want to be sure the function is only executed once, or if you want the ability to execute arbitrary functions, you can pass an optional function as an argument to AtEndOfPath with whatever signature you like and execute it if that argument is not null.
>There would be no one to sue
You underestimate the ability of lawyers to send letters they have been paid handsomely to send. If there is 'my little pony' content findable online, the owners of the site hosting it can be send such a letter. If there's 10 000 sites with a copy of such material, it can still be beneficial for the trademark owner to get letters sent to all 10k sites. But lets skip this issue in further discussion because I do agree this may be a good way to minimize the impact of such letters sent.
If these comments are of use to you feel free to post more questions here until someone redirects us to /gamedev/ or whatever