Page 2 of 2

Re: Question: Meandering behavior for enemies

Posted: Mon Sep 28, 2020 11:31 pm
by l3lessed
As I understand it, yes. That is creating a basic pathfinding map by taking the automap data from the world. I do not know or have a clue how automap really works in any detail and if it computes over to indoor maps too.

On top of that, indoor environments have a z level (Aka multiple levels), and the outdoor automap is always completely flat (1 level).

Re: Question: Meandering behavior for enemies

Posted: Wed Sep 30, 2020 10:06 pm
by joshcamas
One trick I use for my pet mod I'm working on is to detect if the enemy's senses has a target. If it does, then enable the EnemyMotor. Otherwise, disable the EnemyMotor and take control of the enemy. Obviously this doesn't solve the meandering issue, of course. As for that, I imagine it could pick a random position, and if it is in line of sight, move there? And if it ends up stopping (hit a wall) for a certain amount of time, pick a new point?