Like the title says, I want to learn how to make an AI that would do very specific things in game. I want to make a bunch of enemies that act intelligently enough to become a challenge for the player, such as the following:
It would try to find areas that would be the most probable pathway for an enemy to pass through…
[INDENT]Then try to find a vantage point where it could view an area that covers 90% of the width of said area…
But also position itself to reveal only 10% of its surface area to anything within that pathway.
Sniper_actor would automatically shoot enemies, even at distances further than 1km away.
Sniper_actor would be able to shoot through walls. It would only do so when the enemy stays out of sight for over 2 seconds.
Sniper_actor would shoot at where it thinks the enemy went according to his velocity when last seen, and if he thinks the enemy is cowering in a corner.
Sniper_actor would also be able to know the enemy’s exact position if a comrade has line-of-sight on them.
Sniper_actor would also keep its crosshairs on the position where the enemy was previously in case they try to peek-and-shoot at it.
It would try to keep a minimum distance of 250m…
If an enemy tries to come closer, Sniper_actor would be trying to back away.
If an enemy comes closer than 120m then Sniper_actor would switch to its sidearm.
As soon as Sniper_actor reaches that minimum distance, it would try to fulfill the first four lines above.[/INDENT]
The Engineer_actor has the purpose of positioning other actors in the game, mostly things like deployable cover, mines, turrets, and drones.
Each actor should have different places for them to be positioned at.
Looks back at what I wrote…
No, this is way too much, sorry.
Okay, this is too much. I just wanted to know how to do a few things:
Have an actor find out what would likely be a high traffic area for a certain group of actors. This would enable Sniper_actor to do stuff highlighted in red.
Get an actor to check how much exposed surface area they have on them. This would make Sniper_actor be able to do the stuff highlighted in green.
Get an actor check how much distance they have away from another actor. This would make Sniper_actor able to to stuff highlighted in blue.