diff options
Diffstat (limited to 'npc/craft/options.txt')
-rw-r--r-- | npc/craft/options.txt | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/npc/craft/options.txt b/npc/craft/options.txt index fb23c7fd2..3928adff1 100644 --- a/npc/craft/options.txt +++ b/npc/craft/options.txt @@ -426,6 +426,10 @@ function script csys_ArmorFix { array_remove(@csys_penalty, VAR_ITEMDEFPOWER); array_remove(@csys_penalty, VAR_MDEFPOWER); + // If the options were wiped, add a random one + if (getarraysize(@csys_attr) == 0) + array_push(@csys_attr, VAR_MAXHPAMOUNT); + // Save for csys_BonusCalc @csysArmor=CSYS_ARMOR; @@ -454,12 +458,13 @@ function script csys_WeaponFix { .@sub=getiteminfo(getarg(0,Acorn), ITEMINFO_SUBTYPE); @csysArmor=0; - // Only remove one; There is a rationale for this: - // If you go only with defense level 1, it'll break item. - if (any(true,false)) - array_remove(@csys_attr, VAR_ITEMDEFPOWER); - else - array_remove(@csys_attr, VAR_MDEFPOWER); + // Remove the defense options + array_remove(@csys_attr, VAR_ITEMDEFPOWER); + array_remove(@csys_attr, VAR_MDEFPOWER); + + // If the options were wiped, add a random one + if (getarraysize(@csys_attr) == 0) + array_push(@csys_attr, VAR_MAXHPAMOUNT); // Weapon Subtype if (.@sub == W_FIST || .@sub == W_KNUCKLE) |