Hi,
I’m playing with UAIPerceptionComponent and UAISenseConfig_Sight. I managed to make it work but I have some questions regarding DetectionByAffiliation. In every example I have found bDetectEnemies, bDetectNeutrals and bDetectFriendlies are always set to true. Is it right way to handle it? I would like my AI to completely ignore all friends and neutrals and do note sens them at all. How can I set up complex relations between actors?
Best regards,
The last I heard from Epic (in one of their live streams) was that the affiliation stuff wasn’t working properly. Not much work has been done with the AI system since so I think it’s still broken. Instead of using it, what we do is turn on detection of all affiliations and write our own code for detecting friendlies/enemies/etc.The logic is pretty straight forward so it’s not much of a problem to implement yourself.
No problem. I use an Enum and basic logic that compares two affiliations to see if they’re the same or not. But I’m just using two teams and no neutrals. For complex factions you’d need to use complex logic – and there are a lot of possible variations. If you need help with the specifics then post more questions. GL!