iwd2::cg: initial priest spell learning support

domain spells require a different approach;
iwd2 spells don't have classmask set, so checking whether we're a cleric,
ranger, druid or something else has to be done differently;