Commit Graph

16740 Commits

Author SHA1 Message Date
nhmall
b4cd1d6ee0 remove unnecessary paragraph 2024-03-28 10:09:59 -04:00
nhmall
c80bb1990d some Windows build doc updates and typo fixes 2024-03-28 10:06:08 -04:00
PatR
636432e883 variant spellings of "master lich"
From a reddit thread:  after genociding "arch-lich", player's next
target was "master-lich".  The character was a monk who immediately
died of genocide.

("Master<almost anything>" other than "master mind[ ]flayer" or
"Master Thief" or "Master Assassin" matches level 30 monk rank "Master".)

Rather than muck about with fairly complicated matching code, just add
"master-lich" and "masterlich" as explicit variations.
2024-03-28 03:10:38 -07:00
PatR
c6992777f5 end-of-game attribute disclosure in wizard mode
Disclosing final inventory while wearing an alchemy smock reported
the apron's slogan accurately but then disclosing attributes gave
different text if it was conferring poison resistance and/or acid
resistance.  The extra text was unneeded/unwanted there anyway, so
simply suppress it rather than force it to be accurate.

3.6.x had the same issue but it wasn't detectable there because it
only had extra text for T-shirts and they don't confer attributes.
2024-03-27 23:52:37 -07:00
nhmall
9955b2364b update sys/windows/Install.windows 2024-03-27 16:44:40 -04:00
nhmall
5355ee67e2 follow-up: fix copy-and-paste error 2024-03-27 16:25:33 -04:00
nhmall
bb2fef0f7d rework Windows build instructions 2024-03-27 16:20:06 -04:00
PatR
18baf188ea fix github issue #1220 - shattering unseen weapon
Reported by NetSysFire:  if hero dealt a weapon-shattering melee
blow to an unseen target, the weapon was accurately described in
the accompanying message
|Its <formatted-weapon-description> is shattered from the force...!

If the hero can't see or sense the monster, report
|Its weapon is shattered from the force of your blow!

If the monster isn't seen but is sensed, then
|<Monster>'s weapon is shattered from the force of your blow!

Fixes #1220
2024-03-26 13:29:29 -07:00
PatR
fddc966a3e alternate symbol parsing
Make the array of alternate symbol names 'static' and move it to the
top if its routine.

Add S_suit as another alternate for S_armor.
2024-03-26 11:22:42 -07:00
nhmall
1864480522 get rid of a [-Wformat-overflow=] warning 2024-03-26 08:25:32 -04:00
nhmall
66f92ad182 startup sequence and iflags values
early_init() calls decl_globals_init() which zeros out
a number structures:
    ZERO(flags);
    ZERO(iflags);
    ZERO(a11y);
    ZERO(disp);
    ZERO(u);
    ZERO(ubirthday);
    ZERO(urealtime);

Setting values in any of those during startup prior to
the early_init() call was futile, and the values would
get overwritten.

Such was the case with the setting of iflags.colorcount
during Windows startup, so do it after early_init() has
been called.
2024-03-25 22:30:08 -04:00
nhmall
875c83cc2c fix build when ENHANCED_SYMBOLS is not defined 2024-03-25 21:25:27 -04:00
nhmall
80fb1b5f54 provide way for developer to verify custom colors and symbols in effect
' #wizcustom
2024-03-25 20:42:48 -04:00
Pasi Kallinen
058fc0cecf Fix signedness warning 2024-03-25 18:39:21 +02:00
nhmall
652b94ab41 another fix reinstatement 2024-03-25 09:57:53 -04:00
nhmall
2b6d1fa942 reinstate a warning fix 2024-03-25 09:53:52 -04:00
nhmall
7f2af9698f put wintty.c and termcap.c logic to previous 2024-03-25 09:38:54 -04:00
nhmall
dc7df7c407 deal with added field in shuffle_customizations() 2024-03-25 00:15:06 -04:00
nhmall
e3409fd4af reinstate 256 color 2024-03-24 23:47:24 -04:00
nhmall
4d453193cf wintty.c double-check ordering of color on/off 2024-03-24 21:41:32 -04:00
nhkeni
e43564bee4 clarify panic message from #panic 2024-03-24 19:53:48 -04:00
nhmall
29495f77f7 runtime toggle of ENHANCED_SYMBOLS customsymbols 2024-03-24 19:39:36 -04:00
nhmall
780d0912ee indent bit 2024-03-24 17:01:41 -04:00
nhmall
0b35079acc add customcolors option
customcolors (default) and !customcolors toggle whether the
custom colors get applied to the glyphmap.
2024-03-24 16:55:23 -04:00
nhmall
f5c3445e80 a couple of level color tweaks 2024-03-24 15:56:45 -04:00
nhmall
d15ab932e7 more code moves
move an ENHANCED_SYMBOLS function from glyphs.c to utf8map.c
2024-03-24 15:36:19 -04:00
nhmall
17578590ea tidy up glyphs.c a little bit 2024-03-24 15:25:57 -04:00
nhmall
7eecddfdea follow-up to field name change 2024-03-24 11:18:25 -04:00
nhmall
750cf7f619 rename glyphmap nhcolor field to customcolor 2024-03-24 11:04:31 -04:00
nhmall
ec8f237960 config.h comment update 2024-03-24 10:27:42 -04:00
nhmall
e2121ecfab take another stab at shuffle_customizations() 2024-03-24 10:21:19 -04:00
nhmall
8abbb2bca1 unused variable warning fix 2024-03-24 07:22:50 -04:00
nhmall
0b3a0f1b72 follow-up: fix a wintty.c text substitution error 2024-03-24 07:17:40 -04:00
Pasi Kallinen
f131942dd2 Another tamedog message
Give a different message when a peaceful creature was tamed.
Allow suppressing this and the previous message, when the caller
handles messaging.
2024-03-24 10:48:29 +02:00
nhmall
71c78449e5 Windows mswin follow-up 2024-03-23 17:21:18 -04:00
nhmall
8efc329db2 DOS stubs for unfilled functionality 2024-03-23 16:55:56 -04:00
nhmall
340588e907 follow-up fix a regression on color naming 2024-03-23 16:51:51 -04:00
PatR
d2928ce2ba symset customization warning fixes 2024-03-23 13:39:23 -07:00
nhmall
5c43c81018 attempt to fix DOS cross-compile 2024-03-23 15:56:04 -04:00
nhmall
d610d16863 visual studio project file updates for glyphs.c 2024-03-23 15:51:06 -04:00
nhmall
19f1036672 add some custom color glyph definitions to a few symsets
Exercise the previous commit a little.

FIQ's suggested wildcard syntax would make this easier
and a lot less verbose, but that isn't available yet.

This updates (adds some colored walls on specific levels) to the following:

IBMgraphics
IBMgraphics_1
IBMgraphics_2
curses
DECgraphics
2024-03-23 15:41:48 -04:00
nhmall
ba00dc9066 sever extracolors from utf8map and ENHANCED_SYMBOLS
move the custom color data into its own field in the glyphmap
and disassociate it from the unicode/utf8 stuff.

move the glyphcache stuff during options processing and parsing
into new file glyphs.c and out of utf8map.c, and make it
general, and not part of ENHANCED_SYMBOLS.

Do the groundwork for allowing glyph color customizations to
work when any symset is loaded and not restrict it only to
the enhanced1 H_UTF8 symsets.

The customizations in effect are still affiliated with a particular
symset.

Also closes #1224, but the PR itself references a data structure
made obsolete by this commit. The curses comment from the PR was
added into the code.

The PR also made several suggestions, but only the first
one has been included in this commit (and no longer based on
the handler), that being:
"allow defining colors if other symbol handling modes are used
(possibly limited to the standard 16 colors)."

FredrIQ also wrote the following suggestions in PR#1224:

Something I was also contemplating, unrelated to implementation of this
support in curses, would be the ability for the following:

allow defining colors if other symbol handling modes are used (possibly limited to the standard 16 colors)
allow defining attributes (for example: glyph:G_pet_female_kitten:U+0066/red/underline)
allow specifying glyphs as wildcards for defining global color/attribute changes

Something I also want to see are keywords for "don't change the current defined data". If this
were to be added, you could for example do this:
OPTIONS=glyph:G_*_fox:U+0064/blue
OPTIONS=glyph:G_statue_*:basechar/gray/underline
for "make all foxes use a blue color, make all statues gray with underline" without needing
to specify the relevant character for every statue. This ("basechar", "basefg", etc)
should perhaps also be added for MENUCOLORS and statushilites, so that you can, for
example, underline all items being worn without needing to specify a bunch of
near-duplicate rules for combining BUC colors + underline worn items
as per #1064
2024-03-23 15:36:22 -04:00
PatR
ef17c7ac2b unix check_panic_save
Inspired by self-recover, sort of.  Enabled for unix by default; can
be disabled by commenting out '#define CHECK_PANIC_SAVE' in unixconf.h.

When starting the game, if there is no save file to restore and no
lock/level files to recover, check whether a panic save file exists.
If there is one, tell the player that it's there and that it might be
viable, then ask whether to start a new game.

It doesn't convert the panic save into a reconverable one (rename by
nethack, then continue trying to restore) or tell the player how to
make it viable (rename to remove ".e" by game admin), just whether it
is present.  If player opts to start a new game, the panic save is
left alone and will trigger the "there's a panic save file" situation
again once the new game finishes and player starts another.
2024-03-23 10:11:35 -07:00
Pasi Kallinen
4d206c1c40 Make tamedog give a message
People seemed to be confused when a monster next to them was tame
after stepping on a magic trap; this is also an accessibility issue.
2024-03-23 18:37:12 +02:00
Pasi Kallinen
e0cb6e2206 Query menu for putting ring on left or right hand 2024-03-23 13:22:29 +02:00
Pasi Kallinen
720c62c340 Ring of aggravate monster increases level difficulty 2024-03-23 12:35:54 +02:00
Pasi Kallinen
a26f3d1838 yn_function menu code cleanup 2024-03-23 11:05:38 +02:00
Pasi Kallinen
82a698f333 Comment typofix 2024-03-23 10:36:00 +02:00
PatR
19e985fa26 fix #K4123 - pair of u_init.c macros not used
W_MULTSTART and W_MULTEND were last used in nethack 2.3.
Time to finally Get rid of them.
2024-03-22 20:43:15 -07:00
Pasi Kallinen
9a870b5f06 Option to use a menu to answer yes/no prompts
Add a new boolean option 'query_menu'. If on, game will pop up
a menu for specific yes/no questions, instead of using an input prompt.
2024-03-22 19:19:57 +02:00