Haven't tested it, but this is what I came up with.
Code:
/focus [@focus,nomod:alt,help,nodead][@mouseover,help,nodead][help,nodead]
/clearfocus [mod:ctrl]
/cast [@focus,help,nodead][@player,nomod:ctrl] Soulstone
Here's the idea:
/focus- [@focus,nomod:alt,help,nodead] - If focus exists and not holding alt, preserve focus
- [@mouseover,help,nodead] - Fallback to mouseover if exists
- [help,nodead] - Fallback to target if exists
/clearfocus- [mod:ctrl] - Clear if holding Ctrl (overwrites previous line)
/cast- [@focus,help,nodead] - Cast on focus if exists
- [@player,nomod:ctrl] - Fallback to player if not holding Ctrl (prevents casting if you just want to clear focus)
The UI code for
/focus is weird in choosing between the unit in a macro condition or its parameter. It may require further tweaking.