So, I have come up with some code which (I think) would aim/target any clone of your choice, albeit not targeting the closest clone.
So, each clone that you want your AI (or Sprite) to target, must have their x and y coordinates recorded in separate lists (Done for individual x and y variables for more versatility) Then, when instructed, (for example a tank fighting other tanks), it would pick a random list number. This number will be referred to as the “Clone Target Variable” This number will be used to pick the x and y for the AI to point at. (For example, if the CTV is 5, then it would pick row 5 of both lists, and it would be plugged in accordingly).
Then, this tank, would then fire at the said coordinates that was plugged in from the listing, then repeats when it gets ready to fire again.
I might use this for the near future for the bots in WOC, but this is being put to testing for the Airships to give them some type of use beyond just hiding bots underneath it.