I should have coded the AI this way all along, of course. The new guard AI is such a vast improvement over how it was before, and they now behave much like you think they should. This changes the difficulty of the existing levels for the better and puts to rest a long-standing reservation I had about this game.
I got around the lack of full pathfinding by having guards intelligently navigate around obstacles of arbitrary sizes… It essentially hinges on the fact that if you’re in a maze, taking every right hand turn you come across will eventually get you out.
Of course, switching code in mid-stream is not easy with MMF2. I’ve experimentally transitioned to the new AI code in a few previous missions and it all seems to work out fine.
The process of doing this has also made me consider touching up the line-of-sight calculation that all the AIs use. As it stands, it’s a very complex calculation that uses the same code as my bullets. It’s much more computationally intensive than it needs to be, and if I can pull off the refactoring I have in mind, it will dramatically improve framerates.