Diversify patrol behaviour for monsters of different intelligence.

  • I_NORMAL, I_HIGH: as before
  • I_ANIMAL: try to only move within LOS of the patrol point
  • I_INSECT: as animal, but patrol radius is 5
  • I_PLANT : patrol radius is also 5, but there are some other differences:

If the patrol point gets out of sight, zombies don't even attempt to get back. Instead they become confused (not literally, though) and reset their patrol point to 0 (if hostile, thus stop patrolling) or to their current position (to continue "waiting" if friendly). Also, while patrolling, if they reach their target there's a 50% chance of not moving this turn, and 50% the next turn, etc. Especially the latter needs testing. If it looks too stupid even for zombies I'll take it out again.

These changes should also help to make patrolling a bit more efficient because for stupid monsters we have:

  • one los calculation instead of two (patrol point, monster)
  • smaller radius
  • no calculation at all if success is unlikely (distance check)

git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5335 c06c8d41-db1a-0410-9941-cceddc491573

Created by  j-p-e-g  on May 29, 2008
22ORIULMB2NHLFZNJFK2AF275Q6XBKOBE4ZRMOADY64VK5FAUUSQC
Change contents