Wave Based Spawning and Spawner Management
by Jordan Rarrat
Part 1: The Problem
This week, one of my main tasks was refining enemy AI behavior. I decided on using Set Focus from AIController so that the enemy can consistently stay locked onto the closest player however my enemies could not focus and stayed idle.
Part 2: The Solution
I fixed that issue by writing a service node in the behavior tree that runs every tick. this service iterates through all player actors in the world, calculates the distance to each from the enemy and sets the blackboard key to the nearest target. Once the blackboard had the right player assigned, I updated the AI Controller to use SetFocus() on that blackboard value. With this in place enemies now correctly identify and pursue the closest player in real time.
Get Zombats
Zombats
Third-person Ability Shooter
Status | In development |
Authors | Wombat Studios, JRarrat, Josh The Dark, iWannaNuhh, aabunada, Devon Flynn |
Genre | Action |
Tags | 3D, Third-Person Shooter, Zombies |
More posts
- Damage Feedback: Ragdoll Deaths and Screen Flash76 days ago
- Shattering Expectations - Ben Bissett76 days ago
- Sometimes Math is Hard76 days ago
- The Journey to Multiplayer, Part 3 - Joshua Newton76 days ago
- Audio in C++ - Ali Abunada76 days ago
- Guns and Ballistics - Ben Bissett82 days ago
- Proper Ragdolling - Ali Abunada82 days ago
- The Journey to Multiplayer, Part 2 - Joshua Newton82 days ago
- Pause Menu Doubling82 days ago
Leave a comment
Log in with itch.io to leave a comment.