By separating you mean something like this?
Code:
if (field[abilActive].value <> 0) then
~go through all knowledge skills and find an "Arcana" one
foreach pick in hero where "thingid.skKnow"
if (compare(lowercase(eachpick.field[domDomain].text),"arcana") = 0) then
perform #traitprof[skKnow,+,2,"Demon Hunter"]
endif
nexteach
foreach pick in hero where "thingid.skKnow"
if (compare(lowercase(eachpick.field[domDomain].text),"religion") = 0) then
perform #traitprof[skKnow,+,2,"Demon Hunter"]
endif
nexteach
endif
That would be the other way I would think might work. I'm way, way rusty at coding things these days, though. Been a while since I've done a data file.