This commit is contained in:
klorpa
2024-08-31 15:28:42 -05:00
parent 8e85561725
commit 02c4147893
10 changed files with 12 additions and 12 deletions
+1 -1
View File
@@ -9,7 +9,7 @@
* The placements of the NONNULLARG* and NONNULLPTRS macros were done * The placements of the NONNULLARG* and NONNULLPTRS macros were done
* using the following rules: * using the following rules:
* These were the rules that were followed when determining which function * These were the rules that were followed when determining which function
* parameters should be nonnul, and which are nullable: * parameters should be nonnull, and which are nullable:
* *
* 1. If the first use of, or reference to, the pointer parameter in the * 1. If the first use of, or reference to, the pointer parameter in the
* function is a dereference, then the parameter will be considered * function is a dereference, then the parameter will be considered
+1 -1
View File
@@ -796,7 +796,7 @@ newgame(void)
return; return;
} }
/* show "welcome [back] to nethack" message at program startup */ /* show "welcome [back] to NetHack" message at program startup */
void void
welcome(boolean new_game) /* false => restoring an old game */ welcome(boolean new_game) /* false => restoring an old game */
{ {
+3 -3
View File
@@ -984,7 +984,7 @@ beautiful(void)
const char *res; const char *res;
int cha = ACURR(A_CHA); int cha = ACURR(A_CHA);
/* don't bother complaining about the sexism; nethack is not real life */ /* don't bother complaining about the sexism; NetHack is not real life */
res = ((cha >= 25) ? "sublime" /* 25 is the maximum possible */ res = ((cha >= 25) ? "sublime" /* 25 is the maximum possible */
: (cha >= 19) ? "splendorous" /* note: not "splendiferous" */ : (cha >= 19) ? "splendorous" /* note: not "splendiferous" */
: (cha >= 16) ? ((poly_gender() == 1) ? "beautiful" : "handsome") : (cha >= 16) ? ((poly_gender() == 1) ? "beautiful" : "handsome")
@@ -3369,7 +3369,7 @@ use_pole(struct obj *obj, boolean autohit)
* .52125. * .52125.
* .85458. * .85458.
* ...9... * ...9...
* (Note: no roles in nethack can become expert or better * (Note: no roles in NetHack can become expert or better
* for polearm skill; Yeoman in slash'em can become expert.) * for polearm skill; Yeoman in slash'em can become expert.)
*/ */
min_range = 4; min_range = 4;
@@ -3700,7 +3700,7 @@ use_grapple(struct obj *obj)
int clr = NO_COLOR; int clr = NO_COLOR;
any = cg.zeroany; /* set all bits to zero */ any = cg.zeroany; /* set all bits to zero */
any.a_int = 1; /* use index+1 (cant use 0) as identifier */ any.a_int = 1; /* use index+1 (can't use 0) as identifier */
start_menu(tmpwin, MENU_BEHAVE_STANDARD); start_menu(tmpwin, MENU_BEHAVE_STANDARD);
any.a_int++; any.a_int++;
Sprintf(buf, "an object on the %s", surface(cc.x, cc.y)); Sprintf(buf, "an object on the %s", surface(cc.x, cc.y));
+1 -1
View File
@@ -1801,7 +1801,7 @@ arti_invoke(struct obj *obj)
any = cg.zeroany; /* set all bits to zero */ any = cg.zeroany; /* set all bits to zero */
start_menu(tmpwin, MENU_BEHAVE_STANDARD); start_menu(tmpwin, MENU_BEHAVE_STANDARD);
/* use index+1 (cant use 0) as identifier */ /* use index+1 (can't use 0) as identifier */
for (i = num_ok_dungeons = 0; i < svn.n_dgns; i++) { for (i = num_ok_dungeons = 0; i < svn.n_dgns; i++) {
if (!svd.dungeons[i].dunlev_ureached) if (!svd.dungeons[i].dunlev_ureached)
continue; continue;
+1 -1
View File
@@ -939,7 +939,7 @@ dogfood(struct monst *mon, struct obj *obj)
switch (obj->oclass) { switch (obj->oclass) {
case FOOD_CLASS: case FOOD_CLASS:
fx = (obj->otyp == CORPSE || obj->otyp == TIN || obj->otyp == EGG) fx = (obj->otyp == CORPSE || obj->otyp == TIN || obj->otyp == EGG)
/* corpsenm might be NON_PM (special tin, unhatachable egg) */ /* corpsenm might be NON_PM (special tin, unhatchable egg) */
? obj->corpsenm ? obj->corpsenm
: NON_PM; : NON_PM;
/* mons[NUMMONS] is a valid array entry, though not a valid monster; /* mons[NUMMONS] is a valid array entry, though not a valid monster;
+1 -1
View File
@@ -663,7 +663,7 @@ find_targ(
/* if a long worm, only accept the head as a target */ /* if a long worm, only accept the head as a target */
&& targ->mx == curx && targ->my == cury) /* not tail */ && targ->mx == curx && targ->my == cury) /* not tail */
break; break;
/* If the pet can't see it, it assumes it aint there */ /* If the pet can't see it, it assumes it ain't there */
targ = 0; targ = 0;
} }
} }
+1 -1
View File
@@ -520,7 +520,7 @@ relink_light_sources(boolean ghostly)
ls->id.a_monst = find_mid(nid, FM_EVERYWHERE); ls->id.a_monst = find_mid(nid, FM_EVERYWHERE);
} }
if (!ls->id.a_monst) if (!ls->id.a_monst)
impossible("relink_light_sources: cant find %c_id %d", impossible("relink_light_sources: can't find %c_id %d",
which, nid); which, nid);
} else } else
impossible("relink_light_sources: bad type (%d)", ls->type); impossible("relink_light_sources: bad type (%d)", ls->type);
+1 -1
View File
@@ -408,7 +408,7 @@ getmattk(
/* liches have a touch attack for cold damage and also a spell attack; /* liches have a touch attack for cold damage and also a spell attack;
they won't use the spell for monster vs monster so become impotent they won't use the spell for monster vs monster so become impotent
aganst cold resistant foes; change the touch damage from cold to against cold resistant foes; change the touch damage from cold to
physical if target will resist */ physical if target will resist */
} else if (indx == 0 && attk->aatyp == AT_TUCH && attk->adtyp == AD_COLD } else if (indx == 0 && attk->aatyp == AT_TUCH && attk->adtyp == AD_COLD
&& (udefend ? Cold_resistance : resists_cold(mdef)) && (udefend ? Cold_resistance : resists_cold(mdef))
+1 -1
View File
@@ -1060,7 +1060,7 @@ minimal_xname(struct obj *obj)
bareobj.spe = obj->spe; bareobj.spe = obj->spe;
bufp = distant_name(&bareobj, xname); bufp = distant_name(&bareobj, xname);
/* undo forced setting of bareobj.blessed for cleric (preist[ess]); /* undo forced setting of bareobj.blessed for cleric (priest[ess]);
bufp is an obuf[] so a pointer into the middle of that is viable */ bufp is an obuf[] so a pointer into the middle of that is viable */
if (!strncmp(bufp, "uncursed ", 9)) if (!strncmp(bufp, "uncursed ", 9))
bufp += 9; bufp += 9;
+1 -1
View File
@@ -2703,7 +2703,7 @@ relink_timers(boolean ghostly)
nid = curr->arg.a_uint; nid = curr->arg.a_uint;
curr->arg.a_obj = find_oid(nid); curr->arg.a_obj = find_oid(nid);
if (!curr->arg.a_obj) if (!curr->arg.a_obj)
panic("cant find o_id %d", nid); panic("can't find o_id %d", nid);
curr->needs_fixup = 0; curr->needs_fixup = 0;
} else if (curr->kind == TIMER_MONSTER) { } else if (curr->kind == TIMER_MONSTER) {
panic("relink_timers: no monster timer implemented"); panic("relink_timers: no monster timer implemented");