Magic

Magic

190k Downloads

Armour enchants don't stack properly as attributes.

NightScythe1 opened this issue ยท 2 comments

commented

When checking a Mage's attributes for armour enchants such as 'protection' the attribute will simply read the highest value it can find on one of the armour pieces, and doesn't add up the total. For example, a full set of 'Protection 4' armour will only display as a value of '4' in the protection attribute, the same value as if you only had 1 piece of 'Protection 4' armour equipped.

commented

They are not meant to stack, it is intended to be the highest protection level you have.

I could see maybe adding another set of attributes that adds them together- or, more flexible (but lots more attributes) maybe slot-specific enchantments? Something like protection_helmet I guess?

commented

Ah I see, perhaps a set of 'total' attributes such as protection_total would work? Though it might just be my usecase that's too complicated/specific-
I've been trying to balance certain custom damage types to bypass the 'Protection' enchant (as it reduces all damage types) by giving my classes a 'weakness' multiplied by their current protection level. It works perfectly if their protection level is uniform throughout all their armour (deals more damage to make up for the reduction) but if one or more pieces has a lower value of protection than the others, the damage doesn't scale well anymore and deals too much damage.
For example;
A spell intended to deal 10 damage regardless of 'Protection' will have to be scaled up to about 28 damage to bypass a full set of protection 4 (as protection adds 4% damage reduction per level, for a max of 64%) but if a player has only 1 piece of protection 4 (16% damage reduction) the spell/weakness still scales the damage all the way up to 28, resulting in the player taking 23 hearts of damage & dying instantly