Page 1 of 1

Realistic

Posted: Mon Jan 21, 2019 6:41 am
by Ctelfelics
Hello, please tell me how to make that AI did not find the main character in the bushes or under the light, I was told that AIAnchor, but you can more setting?

Re: Realistic

Posted: Mon Jan 21, 2019 7:14 am
by lavizh
Maybe you can occlude the area?
https://docs.cryengine.com/pages/viewpa ... d=29441748

But this should be handled with the vegetation.

Re: Realistic

Posted: Mon Jan 21, 2019 7:30 am
by Ctelfelics
Maybe you can occlude the area?
https://docs.cryengine.com/pages/viewpa ... d=29441748

But this should be handled with the vegetation.
I don't need to hide resources, I need to "hide" from AI

Re: Realistic

Posted: Mon Jan 21, 2019 1:37 pm
by OrkhanAliyev
Well, two of these you mentioned are not exactly the same things. Perceiving the object depending on a light, could be done under some different sequences(like, get the all lights around you, and their radius, then, their intensity, and decide if AI can perceive the object you want). As for the bushes thing, you can either hide the Player with area triggers' help when he's in the bushes or can decrease the AI's FOV so he may not to see the Player easily.(The FOV thing goes for the seeing an object under the twilight)

Re: Realistic

Posted: Mon Jan 21, 2019 3:15 pm
by Ctelfelics
Well, two of these you mentioned are not exactly same things. Perceiving the object depending on a light, could be done under some different sequences(like, get the all lights around you, and their radius, then, their intensity, and decide if AI can perceive the object you want). As for the bushes thing, you can either hide the Player with area triggers' help when he's in the bushes or can decrease the AI's FOV so he may not to see the Player easily.(The FOV thing goes for the seeing an object under the twilight)
can you be a little more specific about the light detection?

Re: Realistic

Posted: Mon Jan 21, 2019 3:35 pm
by Ctelfelics
Here, for example, remember the level in Crysis 3, when you tower suggestions the lasers and shoot rockets like disturbed is no longer shooting at you, and another level where attacked by aliens and not lasers, and the light you Shine. That's how they did the light detection, at least for me..sorry for my translation, I am Russian, I use a translator

Re: Realistic

Posted: Mon Jan 21, 2019 4:40 pm
by OrkhanAliyev
If the scene you want is completely dark(there's no bright area or environment is not illuminated enough to make someone visible), I recommend you to decrease the AI's FOV.
If area has got the lights at different places in different intensities, then, it becomes little bit harder(By the way, sometimes AI can select some weapons with attachments like flashlights and etc, if you want your system to include those situations, then you have to work little more, but what I will tell you won't encompass that but will be about the lights that you know their exact position)

I think you're looking for a Flowgraph tip. I'd rather doing this through C++ than Flowgraph but, my way would be like this with Flowgraph:
1. Add area members like(Sphere,box and change the radius/size according to the light properties)
2. When player is in the sphere or the box, I'd get the distance between the light and Player and the light intensity. If the light intensity is greater than the value can make someone/something visible, and Player is close to that light enough, I'd change the AI's FOV. (Make sure you're not getting that distance between them each frame, it can be unnecessarily expensive :D )

This is not the recommended way to do this. Especially with the Flowgraph conditions. I told this to give an idea to you so you may develop something better.