itermonarr comments
Fix several typos/thinkos about 'itermonsiz' and remove an obsolete remark about 'monarr'.
This commit is contained in:
@@ -4111,8 +4111,8 @@ static unsigned itermonsiz = 0; /* size in 'monst *' pointers */
|
|||||||
void
|
void
|
||||||
alloc_itermonarr(unsigned count)
|
alloc_itermonarr(unsigned count)
|
||||||
{
|
{
|
||||||
/* if count is 0 or bigger than itemarrsiz or much smaller than
|
/* if count is 0 or bigger than itermonsiz or much smaller than
|
||||||
itemarrsiz, release itermonarr (add reset itermarrsiz to 0) */
|
itermonsiz, release itermonarr (add reset itermonsiz to 0) */
|
||||||
if (!count || count > itermonsiz || count + 40 < itermonsiz) {
|
if (!count || count > itermonsiz || count + 40 < itermonsiz) {
|
||||||
if (itermonarr)
|
if (itermonarr)
|
||||||
free((genericptr_t) itermonarr), itermonarr = NULL;
|
free((genericptr_t) itermonarr), itermonarr = NULL;
|
||||||
@@ -4133,7 +4133,7 @@ alloc_itermonarr(unsigned count)
|
|||||||
/* Iterate all monsters on the level, even dead or off-map ones, calling
|
/* Iterate all monsters on the level, even dead or off-map ones, calling
|
||||||
bfunc() for each monster. If bfunc() returns TRUE, stop iterating.
|
bfunc() for each monster. If bfunc() returns TRUE, stop iterating.
|
||||||
If the game ends during the call to bfunc(), then freedynamicdata()
|
If the game ends during the call to bfunc(), then freedynamicdata()
|
||||||
will need to free 'monarr' for us so we make a copy of it in struct g.
|
will free 'itermonarr'.
|
||||||
|
|
||||||
Safe for list deletions and insertions, and guarantees calling bfunc()
|
Safe for list deletions and insertions, and guarantees calling bfunc()
|
||||||
once per monster in fmon unless it returns TRUE (or game ends). */
|
once per monster in fmon unless it returns TRUE (or game ends). */
|
||||||
|
|||||||
Reference in New Issue
Block a user