summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2010-01-08 22:47:33 +0100
committerBardur Arantsson <bardur@scientician.net>2010-01-08 23:46:24 +0100
commit168355580172b6724957bddc595fb00b407cfe8a (patch)
tree403057fc3ed058dffb1cb7c091f0ec5226cea029 /src
parente6276fe835c0c3ea72a79959b2803b0ee7341ffd (diff)
Import fix from CVS: Fix application of set effects when trap of silent switching is triggered.
Diffstat (limited to 'src')
-rw-r--r--src/traps.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/traps.c b/src/traps.c
index 3e9b2497..181c0bbe 100644
--- a/src/traps.c
+++ b/src/traps.c
@@ -1006,6 +1006,11 @@ bool player_activate_trap_type(s16b y, s16b x, object_type *i_ptr, s16b item)
{
object_type tmp_obj;
+ if (p_ptr->inventory[j].name1)
+ wield_set(p_ptr->inventory[j].name1, a_info[p_ptr->inventory[j].name1].set, FALSE);
+ if (p_ptr->inventory[i].name1)
+ takeoff_set(p_ptr->inventory[i].name1, a_info[p_ptr->inventory[i].name1].set);
+
tmp_obj = p_ptr->inventory[j];
p_ptr->inventory[j] = p_ptr->inventory[i];
p_ptr->inventory[i] = tmp_obj;