Difference between revisions of "Forum:Follower condition and keepdogs"

From NetHackWiki
Jump to navigation Jump to search
(Created page with "{{Forumheader|Watercooler}} <!-- Please put your content under this line. Be sure to sign your edits with four tildes ~~~~ --> What decides whatever monster follows you to ...")
 
 
Line 4: Line 4:
  
 
What decides whatever monster follows you to other level? It needs M2_STALK flag (this group of monsters is described in [[Follower]] article), but there are monster with this flag that refuse to follow you (for example Orcus or Cthulhu from UnNetHack). I thought that condition is M2_STALK, without M3_WAITFORU - but Vlad is happily following me and he have both flags. [[Source:Ref/keepdogs]] is a relevant function but I am not understanding what happens there (I thought that "&& !(mtmp->mstrategy & STRAT_WAITFORU)" should keep Vlad from following). [[User:Bulwersator|Bulwersator]] ([[User talk:Bulwersator|talk]]) 16:00, 23 May 2013 (UTC)
 
What decides whatever monster follows you to other level? It needs M2_STALK flag (this group of monsters is described in [[Follower]] article), but there are monster with this flag that refuse to follow you (for example Orcus or Cthulhu from UnNetHack). I thought that condition is M2_STALK, without M3_WAITFORU - but Vlad is happily following me and he have both flags. [[Source:Ref/keepdogs]] is a relevant function but I am not understanding what happens there (I thought that "&& !(mtmp->mstrategy & STRAT_WAITFORU)" should keep Vlad from following). [[User:Bulwersator|Bulwersator]] ([[User talk:Bulwersator|talk]]) 16:00, 23 May 2013 (UTC)
 +
:There's a large number of lines of code that remove STRAT_WAITFORU. (ex. ''mdef->mstrategy &= ~STRAT_WAITFORU''). That means that the monster is currently waiting for you - that's his strategy right now - not that the monster will wait for you. dog.c is checking for that, not M3_WAITFORU directly. This just means that if you got next to a follower that was meditating, it would not follow you even if it would normally.
 +
:I'm not seeing anything else that should stop them from following you, unless they're carrying the amulet, of course. Are you certain orcus never follows? He wasn't just meditating, fleeing, or carrying the amulet? -- [[User:Qazmlpok|Qazmlpok]] ([[User talk:Qazmlpok|talk]]) 00:14, 24 May 2013 (UTC)

Latest revision as of 00:14, 24 May 2013


What decides whatever monster follows you to other level? It needs M2_STALK flag (this group of monsters is described in Follower article), but there are monster with this flag that refuse to follow you (for example Orcus or Cthulhu from UnNetHack). I thought that condition is M2_STALK, without M3_WAITFORU - but Vlad is happily following me and he have both flags. Source:Ref/keepdogs is a relevant function but I am not understanding what happens there (I thought that "&& !(mtmp->mstrategy & STRAT_WAITFORU)" should keep Vlad from following). Bulwersator (talk) 16:00, 23 May 2013 (UTC)

There's a large number of lines of code that remove STRAT_WAITFORU. (ex. mdef->mstrategy &= ~STRAT_WAITFORU). That means that the monster is currently waiting for you - that's his strategy right now - not that the monster will wait for you. dog.c is checking for that, not M3_WAITFORU directly. This just means that if you got next to a follower that was meditating, it would not follow you even if it would normally.
I'm not seeing anything else that should stop them from following you, unless they're carrying the amulet, of course. Are you certain orcus never follows? He wasn't just meditating, fleeing, or carrying the amulet? -- Qazmlpok (talk) 00:14, 24 May 2013 (UTC)