Merge branch 'NetHack-3.6.2'

This commit is contained in:
nhmall
2019-01-29 22:34:07 -05:00
15 changed files with 74 additions and 46 deletions

View File

@@ -2090,15 +2090,13 @@ aligntyp alignment;
if (!Hallucination)
return align_gname(alignment);
/* Count the roles, so that we can pick one at random. */
int rolecount = 0;
while (roles[rolecount].filecode)
rolecount++;
/* The priest may not have initialized god names. If this is the
case, and we roll priest, we need to try again. */
/* Some roles (Priest) don't have a pantheon unless we're playing as
that role, so keep trying until we get a role which does have one.
[If playing a Priest, the current pantheon will be twice as likely
to get picked as any of the others. That's not significant enough
to bother dealing with.] */
do
which = rn2_on_display_rng(rolecount);
which = randrole(TRUE);
while (!roles[which].lgod);
switch (rn2_on_display_rng(9)) {