pf2e.fyi
From Pathfinder Impossible Magic, which isn't enabled.

Magnetize

SPELL 4
Traditions arcane, primal
Cast
Range touch
Targets 1 willing creature
Defense Reflex
Duration 1 minute

You touch a nearby creature, infusing them with a polarity that attracts all metal projectiles and weapons. Whenever a creature makes a ranged attack with a metal weapon or projectile against a creature within 15 feet of the magnetized target, the magnetized target becomes the target of the attack instead.

Whenever a creature within 15 feet Strikes a creature other than the magnetized target with a metal melee weapon, the attacker takes a –2 circumstance penalty to the attack roll.

Pathfinder Impossible MagicORC