Ok, there's two things I want to do and I do know how to do them, but the way I know is messy and complicated. I want to know if there's some python functions I'm missing that with do these things without having to resort to woefully inefficient loops and nested ifs.
1. Given a religion, I want to find the missionary for that religion (i.e. the FreeUnitClass in that religion's XML entry)
2. I want to be able to destroy all units of a particular unitclass without having to cycle through every unit and check.
Is this possible, or am I stuck with my inefficient design?
1. Given a religion, I want to find the missionary for that religion (i.e. the FreeUnitClass in that religion's XML entry)
2. I want to be able to destroy all units of a particular unitclass without having to cycle through every unit and check.
Is this possible, or am I stuck with my inefficient design?