Righty-o, i'm looking at making something sorta complex here (to me anyway).
I'm looking to trigger certain events when a certain npc comes within and leaves a certain proximity of me (or when i enter a proximity of him). When he is within say 200 units of me, i'd like him to have his usual enemy AI, but when he is beyond those 200 units, i'd like him to have a friendly AI. Don't ask me why, please. There are a bunch of other things i'm looking to trigger when he is within/beyond the proximity, but i can handle those.
AI changes are done via ai_relationships, am i right? I'm pretty sure i can figure the AI side of things out. The proximity trigger is what i really need some help with. Any ideas? Help appreciated as always.