[3.4-dev] Minor bug with summoning

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • PowerWyrm
    Prophet
    • Apr 2008
    • 2986

    [3.4-dev] Minor bug with summoning

    In summon_specific():

    Code:
    	/* Look for a location, allow up to 4 squares away */
    	for (i = 0; i < 60; ++i)
    	{
    		/* Pick a distance */
    		int d = (i / 15) + 1;
    
    		/* Pick a location */
    		scatter(&y, &x, y1, x1, d, 0);
    
    		/* Require "empty" floor grid */
    		if (!cave_empty_bold(y, x)) continue;
    
    		/* Hack -- no summon on glyph of warding */
    		if (cave->feat[y][x] == FEAT_GLYPH) continue;
    
    		/* Okay */
    		break;
    	}
    
    	/* Failure */
    	if (i == 20) return (0);
    The last test should be (i == 60).
    PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
  • Magnate
    Angband Devteam member
    • May 2007
    • 5110

    #2
    Thanks for the report - fixed in both master and v4-master.
    "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

    Comment

    • fizzix
      Prophet
      • Aug 2009
      • 3025

      #3
      Good catch. I think I remember correcting that at some point, but I must have failed on the committing it.

      Comment

      Working...
      😀
      😂
      🥰
      😘
      🤢
      😎
      😞
      😡
      👍
      👎