From gtamalloy]'s All that is items:
Quote
Note: Holy Shield has itypea1=shld (shield), and that is what is restricting it from spawning on scepters. Other potential staffmods that share a similar problem are Poison Dagger (knife), Smite (shield), Double Swing (melee), Stun (melee), Double Throw (throwing), Leap Attack (melee), Concentrate (melee), Frenzy (melee), Whirlwind (melee), and Berserk (melee).
So Smite and Holy shield are the only two palla skills that will not normally spawn on scepters leaving 28 normally available.
Quote
'Staffmod' selection:
First, the game chooses how many skills to add. It will do rnd[100], and add to it the ilvl of the item IF it is being imbued. Then, if higher than 90, 3 skills will be chosen. If higher than 70, 2 skills. If higher tan 30, 1.
After this, it selects the skill id. It will start at a certain value depending on the ilvl:
Above 36: 5
Between 24 and 36: 4
Between 18 and 24: 3
Between 18 and 11: 2
11 or lower: 1
This the becomes a base for all the skill ids. Then, it has a chance to be modified:
20% chance to add 1
50% chance to stay unmodified
20% chance to subtract 1
10% chance to subtract 2
If the item is low quality, then the skill id as of now is capped at 4. Then the final id is chosen from the formula below. skill_adder is the skill id so far, base_id is the starting id for the character class.
id = skill_adder + (base_id + 4 * skill_adder) - 5 + rnd[5]
If this ends as 73 (Poison Dagger), it will do the rnd[5] again. And finally, the total skill bonus is chosen. It will do rnd[100], and add to that ilvl / 2 if from imbue.
If 90 or above, +3
Between 60 and 90: +2
Lower than 60: +1
This applies to:
ItemType StaffMods
Cloak sin <unused>
Hand to Hand 2 sin
Primal Helm bar
Pelt dru
Wand nec
Voodoo Heads nec
Scepter pal
Staff sor
Orb sor
-Hammerman (slightly correct by gta-maloy])
And finally:
Quote
In very rare cases a skill that normally isn't able to spawn somhow manages to appear on an item (a very popular example is holy shield on scepters). It is believe that if the game fails six consecutive checks while selecting a staffmod that the seventh skill will be placed on the item regardless if it is normally possible or not. I would assume that this was implemented to avoid an error that would either crash the game or stop the item from dropping (which in turn might crash the game).
Holy shield is in the middle of the range, so it will never be precluded by tier level from spawning with anything else, so go nuts and pick the actual maths out of that to work out the probability