Commit Graph

1154 Commits

Author SHA1 Message Date
nethack.allison
c6c17bc00f more Windows CE 2002-07-23 04:52:48 +00:00
nethack.allison
d9dad62838 build fix for files.c
Warwick's plname files.c addition broke the
build on both win32 and CE because NAMES_MAX
wasn't defined.

In win32 it was defined in limits.h, but only
when _POSIX_ was defined.

In CE it just didn't exist in any of the
header files.  Since it was also complaining
about strdup(), I #ifdef'd Warwick's code out
under CE.
2002-07-23 04:51:28 +00:00
warwick
7b5618e03c Enclose savefile format change by STORE_PLNAME_IN_FILE macro. 2002-07-22 09:13:04 +00:00
warwick
16b7d4a099 Store plname in save files (and restore it).
Move get_saved_games() functionality to files.c
Use moved get_saved_games() functionality in Qt windowport.
[also some non-enabled perminv code in Qt windowport]
2002-07-22 06:25:52 +00:00
nethack.allison
0cc5b698d5 Windows CE port addition 2002-07-22 03:20:52 +00:00
nethack.allison
4957a7f5be another follow-up to fname_decode() routine 2002-07-21 16:58:12 +00:00
nethack.allison
2161fbe18c remove unnecessary variable
follow-up to fname_decode() routine
2002-07-21 16:49:19 +00:00
nethack.allison
03cc2afa2e WIN32: file naming
Allow single character variations in player names
to remain unique in file names by encoding rather
than substituting.
"plnam one", "plnam_one", and "plnam~one" at the
"Who are you?" prompt get unique filenames after this patch.
2002-07-21 04:07:32 +00:00
arromdee
74c5eae064 bear trap wizard wishing 2002-07-20 06:45:48 +00:00
nethack.allison
cdec686d09 More untrap message clean-up 2002-07-20 02:07:09 +00:00
nethack.rankin
34bcb2bb2b polyself typo 2002-07-19 01:45:26 +00:00
nethack.rankin
09cb5be946 B01005 - fasting by monks
Implement a suggestion by <Someone> that turns spent in
"hungry" state exercise wisdom for monk characters; also make
turns spent in "satiated" state abuse it instead.
2002-07-17 23:31:12 +00:00
nethack.allison
c286e48570 remove sparks lighting oil
for now at least, until there is more time to look into it.

<email deleted>
> Yet more nitpicking about potions of oil being lit by sparks from axed
> statues, I'm afraid.
>
> Konosja's potions of oil catch light!
> "That will cost you 66 zorkmids (Yendorian Fuel Tax)."
> "That's in addition to the cost of Konosja's potions of oil themselves, of
> course."
> You snuff the lit potion.
>
> a) why is the Fuel Tax on (in this case) six potions the same as on one?
>
> b) if you a)pply-light a potion, it's just "in addition to the cost of
>    the potion". Is Yname2() the right name-function for catch_lit() to
>    be using? It's odd for Konosja to be talking about herself in the
>    third person.
>
> c) Grammar on the snuffing message is wrong for multiple potions.
2002-07-17 23:26:48 +00:00
nethack.rankin
8aa428058c B01003 - showrace display
Enabling the showrace option displays a nonhuman hero in
white rather than in corresponding monster type's usual color.
2002-07-17 23:26:36 +00:00
nethack.rankin
a2bc6f5a71 more fire trap vs golem 2002-07-15 13:59:42 +00:00
cohrs
a21ddbb2bf minetown guards outside the town proper
Pat forwarded a message from the newsgroup in March that the town guards
enforce rules even outside the town proper.  Fix: On room-based town levels,
check if the location is in a room containing subrooms (roomno will often
have a subroom id instead).  On the other levels (e.g. minetn-5), there are
no subrooms, so the whole level is fair game.  Currently, this is valid.
If fancier towns are added in the future, more flags or use of regions may
be required to tell where the town border actually is.  These checks are done
in a new in_town function.
2002-07-15 04:17:13 +00:00
cohrs
b440613866 B04010 - paper golems and fire traps
Paper golems take 100% damage in a fire trap.  Straw is very flammable
unless tightly packed, but straw golems have a lot of surface area, so give
them 50% damage.
2002-07-14 22:10:33 +00:00
cohrs
5d530348d4 containers and objects in special level descriptions
On mazelike levels, containers had to be listed before their objects.  But,
for roomfilled levels, containers had to be listed _after_ the objects.  All
our current levels that use containers with objects are mazelike, so I
changed the room behavior, updating the comment in lev_comp.y to match.
Other items/monsters are still processed in reverse on roomfilled special
levels, but I think this is OK.
2002-07-14 20:17:45 +00:00
nethack.allison
e0db090d3d B04009 ftn msg when blind/!invis and gain see invis.
<Someone> writes:
Why do you "feel transparent" when you gain see invisible from a
fountain when blind and _not_ invisible? Transparency usually refers
to _being_ invisible.

Another try.
2002-07-14 18:29:34 +00:00
nethack.allison
56634c4850 B04009 ftn msg when blind/!invis and gain see invis.
<Someone> writes:
Why do you "feel transparent" when you gain see invisible from a
fountain when blind and _not_ invisible? Transparency usually refers
to _being_ invisible.

Good point. I think this may have been what was intended, but it's
been like this for quite a while.
2002-07-14 18:04:59 +00:00
nethack.allison
19225335bf B04008 Minetown fountain warnings prevent fountain gem/gold discovery
<Someone> writes:
I can accept that losing gold into a fountain recharges it to make it
possible to find a gem in it in future (however weird that is). What
_does_ seem wrong is that receiving a warning about a Minetown
fountain prevents finding gems and gold there.
2002-07-14 17:19:40 +00:00
nethack.allison
24cb5a7e3e do_look at warning co-located with boulder
This does not fix a reported bug where you
can't attack a hidden creature that is
co-located with a boulder, but it might
assist the player in understanding what is
going on.
2002-07-14 15:59:04 +00:00
nethack.allison
67c7c79d66 melon bit and comment
Melons should break when thrown.
Add objects.c comment about "gray stones"
2002-07-14 13:37:48 +00:00
nethack.allison
42bbcb6157 slight cockatrice egg msg change
Move the "Splat" part of the message.
2002-07-14 13:01:04 +00:00
cohrs
909e262a6f B04005 - leash and uncontrolled teleportation
<Someone> reported that after an uncontrolled teleport due to eating a
leprechaun, his leashed pet was still leashed until he took one more step.
The usual approach which included disallowing the teleport seemed wrong in
this case, so I put in an abbreviated version that does its checks but does
not disallow the teleport.  The pet teleports with you in the same cases as
other teleports, but when it doesn't, the leash snaps loose.
2002-07-14 03:06:19 +00:00
cohrs
adc4094d50 dwarvish indecision
<Someone> (and later <Someone>) reported along with several other
things of a dwarf that stood in place and switched between his pick-axe and
broadsword on successive turns.  Fixed by bringing the logic in the two
cases in line.  The code now prefers to leave the hostile dwarf with a weapon.
2002-07-14 02:48:27 +00:00
cohrs
1238854154 R888 - panic while quaffing a potion of levitation
Now that the in_use flag is set for potions being quaffed, use the in_use
flag in general in destroy_item to avoid destroying the in use object, on
the assumption that the caller will call useup when finished.  There are a
few places that set then unset in_use, but these don't currently result in
a call to destroy_item.  The current_wand hack was not removed, since its
logic appears to allow destroy_item to still destroy the item.
2002-07-13 23:06:22 +00:00
cohrs
05e993d48e B04004 - naming polymorph potions
Provide a chance for the player to name a polymorph potion if you dip
something into it and nothing happens.
Also fix several places in dipping and drinking potions where the HUP cheat
would allow you to use the potion a 2nd time, made more important since
the polymorph sequence includes what is currently a unique message.
2002-07-13 22:27:01 +00:00
nethack.rankin
34149babc3 plug fountain & throne SIGHUP cheat
When using a fountain or throne, getting a --More-- prompt
usually means that you're about to be told that it has just dried
up or vanished.  But since that topology change didn't occur until
after the message, players could cheat by forcing SIGHUP instead
of answering the prompt; the resulting save file would retain the
original topology.  So change the dungeon prior to telling the user
about it.

     The `fixes' entry possibly belongs in the tty-specific category
but since the change is to core code I put it in the general section.
2002-07-13 13:11:51 +00:00
nethack.rankin
615d9dde2b B4003 - exercising spell skills
The spellcasting code stopped counting a spell class's skill
exercise once that reached expert, so the only way that it could
end up being flagged as having reached maximum in the #enhance
feedback would be if it had already received enough exercise to
reach the hypothetical level beyond expert while it was still at
skilled or less.

     It also didn't count the exercise if you were restricted in
the spell class, but that wasn't necessary because becoming
unrestricted--which I don't think is even possible for spells at
present--resets the counter back to 0 to discard any exercise
achieved while ineligible.
2002-07-13 12:39:10 +00:00
nethack.rankin
30f6fbb5fe B04002 - blessed gain level vs XL 30
Fix the problem [reported in the newsgroup and forwarded by <Someone>]
of blessed potions of gain level having the possibility of reducing
your experience points if you were already level 30.  The random XP
value that averages "half way to next level" could be less than your
current experience if you had gotten to level 30 via such a blessed
potion or had drunk at least one of same since reaching that level.
This didn't really make any difference to game play since you weren't
losing any levels, HP, mana, or score, but it was visible to users who
enable the `showexp' option.
2002-07-13 12:19:09 +00:00
warwick
ac764db56c Update inventory with hellucination on/off, since it may display
hallucinated icons.
2002-07-12 02:10:51 +00:00
cohrs
35914ed186 R919 - applying lances
Fixes 2 bugs:
1) an impossible() could occur if you applied a lance against a long worm
because the code uses thitmonst to do the hitting, but didn't set bhitpos,
which is required before calling thitmonst.
Add the missing assignment.
2) applying a lance would never mark a knight as a caitiff.  Added a new
check_caitiff function and called it from the 2 existing checks and in
the lance code.
2002-07-11 05:16:27 +00:00
nethack.allison
c0bcc8d292 modify #untrap prompting further
> The intention is, I believe, to cater for the situation where you, a
> chest, and a dungeon-trap are all on the same square; previously
> (C340-71), you wouldn't have been able to check the chest for traps
> because an #untrap in direction '.' would always have tried to disarm
> the dungeon trap. However, since you can't trap-check containers on
> adjacent squares, it'd wouldn't hurt if the question was dispensed
> with when you specify a direction that isn't your square.
>
> (Note that "you cannot deal with traps while trapped!", so there's
> still several situations when you can't trap-check a chest on a
> trap-square, even though you can loot it, until you've untrapped
> yourself; is this really consistent? Should the if(u.utrap) check
> be moved to the "case y:" branch of the switch?)
2002-07-10 12:32:03 +00:00
arromdee
f3db525ac4 chain summoning
This adds a further throttle to chain summoning.  Monsters can only summon
spellcasting nasties if the nasties are lower level than the summoner, which
makes infinite chains impossible (as long as the player figures out which
monster to kill first).
2002-07-09 07:10:21 +00:00
cohrs
568b8de533 kicking and killing an unseen monster
<Someone> reported that kicking [unlike hitting] an unseen monster
to death would leave an "I" on the screen.  This was due to a missing
DEADMONSTER check.  I also noticed that code to avoid leaving an extra "I"
behind when a monster jumps of of the way was only half right, resulting in
an extra "I" anyway.
2002-07-09 04:21:58 +00:00
nethack.allison
40940991bb change GOLD_CLASS to COIN_CLASS 2002-07-08 23:25:53 +00:00
cohrs
1c6535a655 riding speed
While riding, your speed was calculated using the steeds speed only when
moving multi locations.  So, if you were walking step by step, it would use
your speed instead.  Changed this to use the steed's speed any time actual
movement occurs.
2002-07-08 14:02:27 +00:00
cohrs
632e741a52 R853 - Items inside statues lost
If you cast stone to flesh on a statue on a location containing a monster,
the statue would be turned into a corpse and the contents lost.  This
didn't seem to be appropriate for the spell.  Now the contents spill out.
2002-07-08 00:15:27 +00:00
cohrs
e88a6182dd cancellation, polymorphed and unchanging
<Someone> reported that a wand of cancellation would ignore Unchanging,
noting the case of cancelling yourself while polymorphed into a stone golem.
He thought the wand should win, killing the player.  I felt otherwise,
since the case he specified passes the flag allow_cancel_kill == FALSE.
2002-07-07 23:25:43 +00:00
cohrs
40c4800613 B01016 - misplaced "you steal" message after being blasted by an artifact
I saw no straight-forward way to insert the message earlier in the
sequence, so...  I reasoned that you might not yet have a good grasp and
not be able to continue holding the object when reverting form.  So, I made
this into a drop case and made the drop message a rare past tense message.
Past tense is still OK for the other drop cases.
While testing this, I noticed you'd keep stealing even after reverting
form.  Added code to stop this.  Finally, there was a missing MON_NOWEP
call in the stealing code, added it.
2002-07-07 20:22:57 +00:00
nethack.allison
5802922a3d picking up gold
> > On Saturday, 6 Jul 2002, <Someone> wrote:
> > What's the rationale behind using "money" for what used to be
> > "gold" (as in "The hill orc picks up some money" or "You notice
> > you have no money!")? Has the zorkmid been devalued?
[...]
> At least let *leprechauns* pick up gold. Unlike orcs, they're not the
> kind to pick up just "money".
2002-07-07 19:10:17 +00:00
cohrs
1359896784 eating conduct followup
lost the non-EGG case when removing the unnecessary LEATHER, et al, checks.
2002-07-07 15:25:23 +00:00
cohrs
4a5b7ef893 special level alignments
From the newsgroup a while back - special levels w/o a specific alignment
should inherit their alignment from the dungeon.  Some places explicitly
checked the dungeon if the level alignment wasn't set, at least one did not.
2002-07-07 07:18:05 +00:00
cohrs
e8dc88c950 rotten food and veggie conduct
<Someone> reported (in April) that eating cursed tripe, for example, did
not violate vegetarian conduct.  This patch moves the various conduct
checks into common code that is executed before the rotten state of food is
determined.
2002-07-07 05:07:53 +00:00
nethack.allison
efcf8f4d1c avoid some glitches with a handheld compiler I was trying out
src\muse.c(904) : error C2143: syntax error : missing ';' before '__try'
src\muse.c(904) : warning C4091: ' ' : ignored on left of 'int ' when no variable is declared
src\muse.c(904) : error C2059: syntax error : '='
src\muse.c(916) : error C2059: syntax error : '__try'
2002-07-06 16:26:35 +00:00
nethack.allison
72ed171339 message structure bit 2002-07-06 13:28:46 +00:00
cohrs
3a946944a4 B01014 - chop through
The rest of B01014 was fixed by my fix for B03003.  This fix just
changes the verb as suggested.
2002-07-05 17:37:31 +00:00
cohrs
194e43f882 messages when destroying a chest
Remove the special case of "the" vs "a" in chest_shatter_msg(), just
use an/An as appropriate.
2002-07-05 15:58:16 +00:00
nethack.allison
bd7c4e4af8 validate_prefix_locations follow-up2
translate errno in the log file too
check for standard C
2002-07-05 15:38:27 +00:00