Then I’ve created 1 BP character with this C++ class as parent. This will be main class with shared logic and functions. And then from this BP are inheriting two BPs, RedChar and BlueChar in which I’ve set TeamID as UPROPERTY to different values. Configured sense source on both of them and created shared AiController with sight perception, did tick to sense only enemies, however if I for example place two BlueChar in map they will sense each other even thought I only want to sense enemies.
So my question is how could they sense each other ? They should have same TeamID for sure.
Also it seems that GetGenericTeamId method is not even called since no output has been printed.
AAIController also implements IGenericTeamAgentInterface. I think you need to use SetGenericTeamId to make the Controller’s TeamId match the pawn / just use the controller’s team