Quote:
Originally Posted by JLmelenchon
I am talking about survivor that are getting invisible for infecteds after being sneaky, does there is a way to detect that?
|
Do you mean when a player is on a place where is unreachable by bots (Survivors, SI, CI and witch)?
Yes, you can use L4D2_NavAreaTravelDistance between two coordinates. If it returns a value means that the player is connected, if returns -1 means that there is a fail and there is no way for a bot to reach that position.
You should do more than one test, between the suspecting survivor and multiple bots(because the bot could be in an invalid area, not the survivor). If after some tests you don't get a positive value, it means that your survivor is on a disconected nav area and is unreachable.
__________________