Commit Graph

5021 Commits

Author SHA1 Message Date
Pasi Kallinen
19fe4ece8c Move struct istat_s above prototypes using it 2015-06-03 17:41:01 +03:00
Pasi Kallinen
cf28b8ad71 Fix Rogue-level lighting bugs caused by dark room
Found by Boudewijn
2015-06-03 17:27:40 +03:00
nhmall
ddbe9a0521 Merge branch 'win32-x64-working' 2015-06-02 22:36:55 -04:00
Alex Kompel
4083abe286 offer perm_invent as "personal preference" option 2015-06-02 19:20:41 -07:00
PatR
64e0c99b62 enlightenment for unarmored, also blindness
Augment the existing enlightenment feedback for blindness:  "innately"
blind if poly'd into something without eyes, "permanently" blind if
using the blind-from-birth option, "deliberately" blind if blindness
is  solely due to a blindfold, or "temporarily" blind otherwise.

Add status of "not wearing any armor" when applicable, with slightly
different phrasing if it's due to adhering the OPTIONS:nudist conduct.
2015-06-02 17:39:19 -07:00
PatR
a1aebc336c blind-from-birth fix
The Blindfolded_only macro didn't track u.uroleplay.blind so would
give a false positive if wearing a blindfold, not able to see due to
the blind option, and not afflicted with any other blindness factors.
Dipping a worn blindfold into holy or unholy water is supposed to
reveal a glow if that blindfold is the only reason for blindness but
the glow was described even when blind-from-birth.

There's no feedback at all when the glow isn't seen.  I'm punting on
that one.  (This change didn't introduce that, just added one extra
situation where it happens.)
2015-06-02 17:30:16 -07:00
PatR
ad7310bec6 breaking blind-from-birth conduct
OPTIONS:blind starts the hero off blind, but putting on the Eyes of the
Overworld confers sight.  Make that break the blind-from-birth conduct.

Sight persists after removing the Eyes even though they aren't intended
to cure anything.  It doesn't make sense to restore the blind-from-birth
flag when taking the Eyes off, but we may want to add another flag, or
make u.uroleplay.blind into a bit mask that can track both can't-see-now
for play and could-never-see for conduct.  (Actually, u.uroleplay.blind
should track only the conduct, and starting the game with it enabled
should set one of the extra bits in u.uprops[BLINDED].intrinsic.  The
Eyes already override that, and taking them off would restore blindness
since the bit would still be set.  As a bonus, the expression in the
macro 'Blind' could be simplified.)
2015-06-02 16:57:42 -07:00
nhmall
fee1259e60 make option show as disabled
Changes to be committed:
	modified:   src/options.c

make option show as disabled if compile time options aren't defined.
2015-06-02 18:20:07 -04:00
nhmall
04c9fa151f defaults.nh update 2015-06-02 17:41:13 -04:00
nhmall
ab57384a99 win32 raw_printf needs better formatting to read
Changes to be committed:
	modified:   src/options.c

Noticed while testing status bits, the meaningful part of
the message is truncated on WIN32.
2015-06-02 17:20:23 -04:00
nhmall
856b59d8e9 status conditional code commented oout for merge 2015-06-02 17:09:39 -04:00
nhmall
429ad27a74 runtime enable statushilites if compiled in
Changes to be committed:
	modified:   src/options.c

default to runtime enabled of statushilites if compile time option set
2015-06-02 16:55:02 -04:00
Alex Kompel
7840fcf6bc win32_gui: honor use_status_hilites flag 2015-06-01 20:51:09 -07:00
nhmall
83e3d2e853 guidebook status_hilite adjustment 2015-06-01 22:43:34 -04:00
nhmall
66ae23a77e option name change to statushilites
Changes to be committed:
	modified:   doc/Guidebook.mn
	modified:   doc/Guidebook.tex
	modified:   include/flag.h
	modified:   src/options.c
	modified:   win/tty/wintty.c

example:
OPTIONS=statushilites
OPTIONS=hilite_status:hitpoints/30%/bright-magenta/normal
2015-06-01 22:30:04 -04:00
nhmall
9999ba9700 Merge branch 'master' into status_hilite
Conflicts:
	include/extern.h
	win/tty/wintty.c
2015-06-01 22:13:41 -04:00
nhmall
78395b0efe Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-06-01 22:07:19 -04:00
nhmall
e0bc06e5d8 oops, Guidebook.tex paste error 2015-06-01 21:57:54 -04:00
nhmall
c7c5895ad3 ready for testing
Changes to be committed:
	modified:   doc/Guidebook.mn
	modified:   doc/Guidebook.tex
	modified:   include/config.h
	modified:   win/tty/wintty.c
2015-06-01 21:41:00 -04:00
PatR
f0904157c5 tty role selection when filter by options
Honor things like OPTIONS:role=!tourist and NETHACKOPTIONS='race=!orc'
when performing interactive role selection.  I don't think it was
completely correct when players let the program choose, but it must
have been close enough because we haven't gotten any complaints.
The post-3.4.3 interactive selection was ignoring options-base filtering
entirely and did get complaints for the pre-beta.

Role selection has a ton of code which bloats the program without doing
anything useful for actual game play.  It ought to be split off into a
separate front end.
2015-06-01 18:18:47 -07:00
nhmall
ae81924894 functional state achieved
Changes to be committed:
	modified:   win/tty/wintty.c
2015-06-01 19:37:25 -04:00
Alex Kompel
3a9ae2bcbd hilite_status: spaces in color names break option parsing 2015-06-01 08:20:56 -07:00
nhmall
ec92c2007a Merge branch 'master' into status_hilite
Conflicts:
	include/extern.h
	src/options.c
2015-06-01 09:09:44 -04:00
Pasi Kallinen
13ef4962fd Reduce the number of gnomes with candles
Gnomes in mines during level generation have 1/20 chance of getting a candle
(should give approximately 4 candles in all of the mines total), and every
randomly generated gnome has 1/60 chance.
2015-06-01 15:59:43 +03:00
nhmall
67929413ed Merge branch 'status_hilite' of https://rodney.nethack.org:20040/git/NHsource into status_hilite 2015-06-01 08:35:07 -04:00
nhmall
ca8f25d4b6 more updates and on/off option 2015-06-01 08:33:17 -04:00
Alex Kompel
b2042efcfe Merge branch 'status_hilite' of https://rodney.nethack.org:20040/git/NHsource into status_hilite 2015-05-31 21:32:13 -07:00
Alex Kompel
d7ecceaa88 win32-gui: parse value of gold correctly for status hilite 2015-05-31 21:31:27 -07:00
karnov
be4c2b2fd6 Guidebook updates (misc). 2015-05-31 22:29:08 -04:00
PatR
92ec573fbb mondata.c formatting cleanup, ancient AIX PS/2 bug
When looking to see whether the monsndx() panic could provide any more
useful information [if a pointer that's supposed to point into the
mons[] array doesn't, I don't think that there's a whole lot of other
information available aside from whether it is null or not, and that's
implicitly provided already], I went through the whole file cleaning up
the formatting and making sure every routine was preceded by a short
(usually one line) comment.

There were a few bits of code reorganization.  I changed little_to_big
to have a single point of return.  The 25 year old workaround for a
compiler bug on a defunct platform may or may not still be applicable;
I took that out.  If we get segfault reports for AIX on PS/2, this is
the first place to look.  (big_to_little is nearly identical and didn't
have the same workaround.  Not needed, or not called often enough for
any AIX PS/2 user to be affected?)
2015-05-31 17:18:06 -07:00
nhmall
3cb2c66f35 more work on the tty status_hilite code
Changes to be committed:
	modified:   include/wintty.h
	modified:   src/botl.c
	modified:   win/tty/wintty.c
2015-05-31 19:39:28 -04:00
nhmall
1c00f3b8f3 yet more updates
Changes to be committed:
	modified:   include/botl.h
	modified:   include/extern.h
	modified:   include/wintty.h
	modified:   src/botl.c
	modified:   src/options.c
	modified:   src/windows.c
	modified:   win/tty/wintty.c

get the tty versions started
2015-05-31 16:50:08 -04:00
nhmall
40f1dc8bc3 more updates
Changes to be committed:
	modified:   include/botl.h
	modified:   src/botl.c
	modified:   src/windows.c
	modified:   win/tty/wintty.c
2015-05-31 15:18:59 -04:00
nhmall
4bb21a08f2 some code rearrangement/cleanup in botl.c 2015-05-31 14:45:29 -04:00
nhmall
27967d2b3b notify windowport of hilites when status is initialized
Changes to be committed:
	modified:   src/botl.c
2015-05-31 12:06:18 -04:00
nhmall
dd14d12281 more adjustments
Changes to be committed:
	modified:   src/botl.c
	modified:   src/options.c
2015-05-31 11:56:55 -04:00
nhmall
7e4074b61f more status_hilite work
Changes to be committed:
	modified:   include/extern.h
	modified:   src/botl.c
	modified:   src/options.c
	modified:   src/windows.c

defer notification of the window port until after
proper initialization. Options are processed very
early in 3.6.0
2015-05-31 11:54:06 -04:00
nhmall
ef0c00d99b interim updates
Changes to be committed:
	modified:   include/botl.h
	modified:   src/botl.c
	modified:   src/windows.c
	modified:   win/tty/wintty.c

Move the windowport stuff out of botl.c and into windows.c
where it belongs.
2015-05-31 10:26:54 -04:00
PatR
3a5304c49e last? Sting
If Sting is glowing when blindness gets toggled, give a new "glowing"
message.

So instead of
  Sting glows blue! [...] You can't see! [...] Sting stops quivering.
if you're still blind when the last orc goes away, or
  Sting quivers slightly. [...] You can see again. [...] Sting stops
  glowing.
if you were blind when the first orc arrived, now you'll get an
intermediate message between the second and third ones.  'Sting is
quivering' for the first case, 'Sting is glowing' for the second.
No matter how many times blindness toggles back and forth, the final
"stops glowing" or "stops quivering" will be consistent with the most
recent "is glowing" or "is quivering".
2015-05-31 01:24:19 -07:00
PatR
a70599b0cd Sting again
When formatting uwep, verify that warning comes from wielded weapon
before appending "(glowing <color>)".
2015-05-31 00:44:40 -07:00
Pasi Kallinen
36f00f98eb Use a menu to pick a container to tip
If there is more than one container, the #tip command will show a menu;
if there's just one container, prompt for tipping.

As per Boudewijn's suggestion, remove the superfluous
"There is a container here" message.
2015-05-31 10:13:53 +03:00
PatR
0171345aad more Sting,&c
Add "(glowing light blue)" to the formatted object description when
Sting or Orcrist is glowing due to presence of orcs or "(glowing red)"
if Grimtooth is glowing due to elves.  Use "(glowing)" if blind;
assumes that some aspect of the glow (perhaps warmth or vibration) can
be noticed via touch.

Make enlightenment's "you are warned about <monster class> because of
<artifact>" catch up with Orcrist and Grimtooth.  It was attributing
Orcrist's warning against orcs to Sting, and Grimtooth's warning was
against "something" rather than elves.

The glow color is now a new field in artilist[], so the biggest part
of this patch is adding an extra value to each artifact's definition.
2015-05-30 22:41:30 -07:00
nhmall
b4d9aab90a Merge branch 'master' into status_hilite 2015-05-30 22:23:25 -04:00
nhmall
4ccbf2edc8 some updates
Changes to be committed:
	modified:   include/botl.h
	modified:   src/botl.c
2015-05-30 22:22:39 -04:00
nhmall
69596a58b3 Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-05-30 22:07:57 -04:00
nhmall
e27f127a7b some documentation updates
Changes to be committed:
	modified:   dat/history
	modified:   doc/Guidebook.mn
	modified:   doc/Guidebook.tex

- include new 3.6.0 beta testers in dungeoneers list
2015-05-30 22:06:02 -04:00
PatR
24b4872e2f get_cost_from_price
I couldn't figure out why walking over a container in a shop might
give the wrong price; the code looks correct.  But I've reorganized
get_cost_from_price to perform the cheapest tests first.  The u.ushops
check should probably be done in doname to avoid calling this routine
at all 99.99% of the time.
2015-05-30 18:22:14 -07:00
PatR
da64f26844 disoriented teleport attempt
Reported for pre-beta, getting "you feel disoriented" when attempting
to teleport within a level while carrying the Amulet, you still ended
up teleporting.  Wizard mode allows the disorientation to be overridden
but the logic was wrong.  It worked as intended when in wizard mode but
unintentionally always overrode disorientation when not in that mode.
2015-05-30 12:30:54 -07:00
nhmall
54cee6913e Merge branch 'master' into status_hilite 2015-05-30 10:59:39 -04:00
nhmall
d5a8004acf formatting fix 2015-05-30 04:56:24 -04:00