diff options
Diffstat (limited to 'npc')
-rw-r--r-- | npc/craft/options.txt | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/npc/craft/options.txt b/npc/craft/options.txt index 2b2f40ff8..6d718a9f8 100644 --- a/npc/craft/options.txt +++ b/npc/craft/options.txt @@ -399,6 +399,9 @@ function script csys_ArmorFix { // Remove penalties array_remove(@csys_penalty, VAR_ITEMDEFPOWER); array_remove(@csys_penalty, VAR_MDEFPOWER); + + // Save for csys_BonusCalc + @csysArmor=true; return; } @@ -420,6 +423,10 @@ function script csys_BonusCalc { if (.@base >= (.@avg+1)*7/10) .@base=rand2(1, .@avg+1); + // Armor? Crap it to 25% + if (@csysArmor) + .@base=.@base/4; + return .@base; } @@ -441,6 +448,8 @@ function script csys_Apply { getinventorylist(); if (getiteminfo(@inventorylist_id[.@id], ITEMINFO_TYPE) == IT_ARMOR) csys_ArmorFix(); + else + @csysArmor=false; // Shuffle the arrays array_shuffle(@csys_attr); @@ -495,7 +504,8 @@ function script csys_Apply { .@slt+=1; } - // The options have been attributed + // The options have been attributed, clear temporary variables + @csysArmor=false; return; } |