summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Howard2008-06-11 00:14:07 +0000
committerSimon Howard2008-06-11 00:14:07 +0000
commit6ec196ca814344336c1f8868fe21e8ff9f25f58e (patch)
treea34b14f94c38164564b7aea0fa3b1c8321fedac7
parente04445dd0766dc77b818c76c85b44c2aadbf71ac (diff)
downloadchocolate-doom-6ec196ca814344336c1f8868fe21e8ff9f25f58e.tar.gz
chocolate-doom-6ec196ca814344336c1f8868fe21e8ff9f25f58e.tar.bz2
chocolate-doom-6ec196ca814344336c1f8868fe21e8ff9f25f58e.zip
Only apply dehacked green armor class to the green armor shirt, not the
armor helmets as well. Subversion-branch: /trunk/chocolate-doom Subversion-revision: 1146
-rw-r--r--src/deh_misc.c5
-rw-r--r--src/p_inter.c4
2 files changed, 5 insertions, 4 deletions
diff --git a/src/deh_misc.c b/src/deh_misc.c
index 11a7bc48..c8107858 100644
--- a/src/deh_misc.c
+++ b/src/deh_misc.c
@@ -62,9 +62,8 @@ int deh_max_armor = DEH_DEFAULT_MAX_ARMOR;
// This is the armor class that is given when picking up the green
// armor or an armor helmet. See P_TouchSpecialThing in p_inter.c
//
-// Question: Does DOS dehacked modify the armor helmet behavior
-// as well as the green armor behavior? I am currently following
-// the Boom behavior, which is "yes".
+// DOS dehacked only modifies the behavior of the green armor shirt,
+// the armor class set by armor helmets is not affected.
int deh_green_armor_class = DEH_DEFAULT_GREEN_ARMOR_CLASS;
diff --git a/src/p_inter.c b/src/p_inter.c
index 64b9bc81..ee91bcd6 100644
--- a/src/p_inter.c
+++ b/src/p_inter.c
@@ -392,8 +392,10 @@ P_TouchSpecialThing
player->armorpoints++; // can go over 100%
if (player->armorpoints > deh_max_armor)
player->armorpoints = deh_max_armor;
+ // deh_green_armor_class only applies to the green armor shirt;
+ // for the armor helmets, armortype 1 is always used.
if (!player->armortype)
- player->armortype = deh_green_armor_class;
+ player->armortype = 1;
player->message = DEH_String(GOTARMBONUS);
break;