|
Hey, thanks for the reply. The priority condition just helps you search for specific events in case you don't want to search for all events. For example, if there's enemy events and door events on the map, most cases you won't want to see if the door events are closest, just the enemy events. So having that priority helps with that. But not just enemy and ally events. Perhaps you may want to search for which item, door, lever, or any other kind of event which is closest too.
Radial detection would be preferable. I would like it to be called because this script should just return the closest unit's map x and y values to store in game variables so that way I can use, say, a pathfinding script to move an event towards the detected event.
In other words, this script should just detect the location of the unit given the specified priority and store it in game variables that you can specify in the script (for example, a setting in the script like detectx = choose which variable ID), and not detect whether or not a specific unit is closest as if it were a true false value.
Hope that helps. I think many others may find such a script useful too as I've not seen any scripts available that detect events closest to other events.
|