Commit Graph

15069 Commits

Author SHA1 Message Date
nhmall
0282e0b1fd doc error for .nethackrc location on Windows 2023-02-03 16:48:54 -05:00
nhmall
f348deb2bc CI not catching macOS sound-related warning/error
Add WANT_MACSOUND=1 to the build so we get informed of warnings
and errors in any of the macsound-related files.
2023-02-03 15:33:47 -05:00
nhmall
9d3dda1e1d mac typo and some warnings 2023-02-03 15:12:42 -05:00
nhmall
a5c7ca1a29 another follow-up: be consistent 2023-02-03 14:43:56 -05:00
nhmall
583848b04c minor wording change 2023-02-03 14:40:58 -05:00
nhmall
eda74d1d0d updated fixes3-7-0 with sound entries 2023-02-03 14:39:07 -05:00
nhmall
d9a6e581a1 paste error 2023-02-03 14:04:12 -05:00
PatR
3e6ea3faed fix #K3857 - hiding while trapped in a non-pit
sanity_check feedback which occurred after using locking magic to
set off a bear trap at the location of a monster hiding under an
object.

Trivial bit: a recent change made stunning via knockback only occur
when not already stunned but was still adding the current stun time
to the new stun time even though current stun is now always zero.

Several formatting bits included.
2023-02-03 10:45:59 -08:00
nhmall
9931d05fc2 follow-up: a couple of documentation errors 2023-02-03 13:40:13 -05:00
nhmall
2acd8e7b29 update soundlib interface
Add SOUND_TRIGGER_AMBIENCE
2023-02-03 13:32:44 -05:00
Pasi Kallinen
1b5414c833 Add some variation to minefill levels
Randomize the number of objects and monsters a little bit,
they're still roughly the same as before.
2023-02-03 19:10:04 +02:00
Pasi Kallinen
d95e6adbdd Fix extern def 2023-02-03 17:12:23 +02:00
Pasi Kallinen
0722a5c2dd Fix punishment iron ball yanking hero on top of a monster
When attached iron ball was in a pit (or a pool) with a monster,
and your levitation ended, you were put on top of the monster.

Add a sanity check for hero over monster.
2023-02-03 08:51:48 +02:00
Pasi Kallinen
cae29f1dfd Comment typofix 2023-02-02 19:07:56 +02:00
Pasi Kallinen
8535b248c8 Fix ceiling hiders on pools
While fuzzing, I saw a sanity checking error complaining about
a ceiling hider being on top of a pool; the rock piercer was
teleported on top of the pool while it was hiding in the ceiling.

Try to be a bit more consistent when a monster is hiding in ceiling,
and if it's valid for it to be on a pool.
2023-02-02 19:04:51 +02:00
Pasi Kallinen
c2a1b97627 Stun from knockback only if not already stunned 2023-02-02 13:50:59 +02:00
Pasi Kallinen
6af26751e6 Monsters never try to pick up ball or chain
Apparently my m_move reorg made it possible for monsters to
pick up the chain attached to hero; explicitly prevent that.
2023-02-01 21:43:26 +02:00
nhmall
b45895c01d correct a predefined preprocessor macro for clang 2023-02-01 14:15:34 -05:00
nhmall
3214335bb5 undefine X11_BUILD after hack.h or config.h
So as not to complicate any onefile efforts by leaving it defined.
2023-02-01 14:04:20 -05:00
nhmall
d4a111083a avoid some issues with c++ and X11 2023-02-01 10:41:04 -05:00
nhmall
79d8f95f57 don't make the catch inline 2023-02-01 10:16:22 -05:00
nhmall
d90fa596a3 refine detection by compiler version in tradstdc.h 2023-02-01 09:55:41 -05:00
nhmall
a5ed0d0363 follow-up 2023-02-01 09:41:35 -05:00
nhmall
14962a5a33 catch use of pre-C99 non-standard functions 2023-02-01 09:22:16 -05:00
Pasi Kallinen
56f1201e43 Use strchr, not index 2023-02-01 16:10:41 +02:00
Pasi Kallinen
df8a0ac654 Split monster looking for items into separate function 2023-02-01 14:37:12 +02:00
Pasi Kallinen
6c9700ab25 Monster movement and object pickup cleanup
Clean up some of the code for monster deciding what objects
to pick up, removing duplicate code.  There should be no real
difference in behaviour, other than monsters now can pick up
one stack of items at a time; previously monster could pick up
gold, then a practical item, followed by a magical item all
in a single turn, although this very rarely mattered.

Not extensively tested.

Code originally from NetHack4.
2023-02-01 10:23:23 +02:00
nhmall
56d4822f4e prototype was within #ifdef block, function wasn't
Move the prototype in extern.h
2023-01-31 23:05:15 -05:00
nhmall
8ee42f5644 further work on soundlib support code
move some inline code into functions
replace some magic numbers

The mingw code is not tested yet.
2023-01-31 22:19:29 -05:00
Pasi Kallinen
4ccee5a177 Use could_reach_item 2023-01-31 19:09:43 +02:00
Pasi Kallinen
97d7a735a4 Separate function for monster safe touch object
Also added the check for touching an artifact to it
2023-01-31 18:44:13 +02:00
nhmall
e6012ab658 Only embed wav resources if soundlib defined 2023-01-31 02:22:25 -05:00
nhmall
f2dc7f308d missed a reference in a header file 2023-01-31 01:29:23 -05:00
nhmall
20c7a217ba mingw follow-up 2023-01-31 01:13:03 -05:00
nhmall
2c5bbdc0ed fix a naming conflict 2023-01-31 01:10:02 -05:00
nhmall
ce0a4f60ca more windows Makefile tinkering
It looks like the Windows API call for PlaySound using SND_RESOURCE, from a
mingw32 built program, cannot find the resources that are
embeded into the .exe by the mingw32 resource compiler. That works fine
from visual studio.

For now, fall back to not using the SND_RESOURCE flag, use an ordinary
wav file name in the filesystem. Makefile.mingw32 has been modified
to copy the wav files to the binary directory along with the exe.

This probably won't be the final approach, but it will get things
working for now.
2023-01-31 00:45:27 -05:00
nhmall
a7b8099ecb some Makefile.nmake fixups 2023-01-30 19:24:21 -05:00
nhw_cron
5bf0bc3ba4 This is cron-daily v1-May-8-2022. 005guidebook updated: doc/Guidebook.txt 2023-01-30 12:37:14 -05:00
nhmall
9bbb2e17cf add a master off/on switch for sounds
sounds can be set in the config file or on the fly with the Options menu.

This also adds a mechanism for specifying a terminology preference
for a boolean option in the options menu.

The choices are: Term_False, Term_Off, Term_Disabled

Term_False, the default, will use the terms "false" and "true" in the
Options menu.
Term_Off will use the terms "off" and "on" in the Options menu.
Term_Disabled will use the terms "disabled" and "enabled" in the Options
menu.

I didn't review any of the existing options to see if one of the new
alternative terms might be a better fit. They were all left at the default.
2023-01-30 12:07:03 -05:00
Pasi Kallinen
fe99bcd591 Hellfill: Lich
Similar to the fake wizard towers.
2023-01-30 18:30:39 +02:00
Pasi Kallinen
71f900f174 Add helltweaks to fake wiz towers 2023-01-30 17:58:51 +02:00
Pasi Kallinen
a4c15f23bc Add helltweaks to wizard3 2023-01-30 17:47:21 +02:00
Pasi Kallinen
788492bdcd Add helltweaks to wizard2 2023-01-30 17:43:34 +02:00
Pasi Kallinen
7def7ece92 Add helltweaks to wizard1 2023-01-30 17:31:25 +02:00
Pasi Kallinen
744d64487b Helltweaks: improve lava river
The lava river will now draw another river, until a certain
amount of map locations have been turned into lava, so you don't
get a teensy "river" made out of 2 lava pools.

Add a lua selection method to count the number of locations
in the selection.
2023-01-30 17:10:39 +02:00
nhmall
c7464e8aa5 purge some never-used fields from iflags 2023-01-30 09:03:47 -05:00
Pasi Kallinen
8eeeec41f5 Avoid repeating the god ray
My recent change to hit and wake monsters caused a recursive
ghod_hitsu -> wakeup -> dobuzz -> buzz -> ghod_hitsu loop.
Don't call the ghod_hitsu again if the priest is already angry.
2023-01-30 12:39:35 +02:00
nhmall
8bb1feab61 remove a value used for a test run of nmake 2023-01-29 22:09:54 -05:00
nhmall
6ce2994646 Windows Makefiles easier soundlib opt-in or opt-out 2023-01-29 22:07:31 -05:00
Pasi Kallinen
77797450f5 Remove obsolete comment 2023-01-29 18:49:58 +02:00