Defensive Shock

Evocation [electricity]
Level: Alchemist* 2, Artificer * 2, Bloodrager * 2, Magus * 2, Sorcerer */Wizard * 2
Components: V, S, M (a hollow metal sphere)
Casting Time: 1 Standard Action
Range: personal
Target: you
Duration: 1 minute/level or until discharged
Saving Throw: -
Spell Resistance: -
  Electrical energy floods your body, shocking the next creature that touches you. Any creature striking you with its body or a handheld weapon takes 1d6 points of electricity damage per two Caster Levels (maximum 6d6). If the attacker has spell resistance, it applies against this damage. Each time the spell discharges, the number of damage dice it deals is halved (rounded down when the spell's damage dice reach 0, the spell ends.