I don't know if it will help you, because it would mean for you to compile WME from sources.
In my wme branch (
https://bitbucket.org/hardcoredaniel/wme1-rapaki-edition), I have added a functionality which might be useful for you. The changes to WME are this one commit:
https://bitbucket.org/hardcoredaniel/wme1-rapaki-edition/commits/4bb8b5772fdcd30de18ef5be2c38d292a9dc2905and the one relevant change from this commit that fixes a previous error on my side:
https://bitbucket.org/hardcoredaniel/wme1-rapaki-edition/commits/c577842f67312f498d31c9f45057af3e51da8f37The idea behind this is to utilize when an actor is being "blocked", i.e. the actor cannot move into the "originally intended" direction anymore. The change in the engine will generate an event that you can use for your purpose (called "ActorIsBlocked") and there is also a field "ActorIsBlocked" for every actor to check which ones are blocked.
Additionally, you can override the default behaviour of the engine, which tries to keep the actor moving using a new path around the blocked region. When you call the function "SetStopOnBlocked(true)" then the actor will simply stop walking.
I did not have the time yet to create a pull request for the original WME source tree, to have these features included eventually. My branch might contain other stuff which you might not want, so I cannot recommend to use it over the original WME.