confused remove curse

When confused remove curse acts upon an object to randomly bless or
curse it, clear the bknown flag.  Do this for all objects which get subjected
to the effect, even ones which are already blessed or cursed and hence don't
change state.
This commit is contained in:
nethack.rankin
2005-04-15 02:59:03 +00:00
parent 4e9c26fc28
commit 15f309d118
2 changed files with 5 additions and 1 deletions
+4 -1
View File
@@ -1,4 +1,4 @@
/* SCCS Id: @(#)read.c 3.5 2005/03/28 */
/* SCCS Id: @(#)read.c 3.5 2005/04/14 */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/* NetHack may be freely redistributed. See license for details. */
@@ -970,6 +970,9 @@ struct obj *sobj;
if (confused) {
blessorcurse(obj, 2);
/* lose knowledge of this object's curse/bless
state (even if it didn't actually change) */
obj->bknown = 0;
/* blessorcurse() only affects uncursed items
so no need to worry about price of water
going down (hence no costly_alteration) */