function getAllowableForm($mask, $as_ref = 1)
{
    $gSpellSnapeshiftForm = getFormNames();
    if ($as_ref) {
        return getListFromArray_1($gSpellSnapeshiftForm, $mask, "?s=s&form=%d");
    }
    return getListFromArray_1($gSpellSnapeshiftForm, $mask);
}
function getAllowableRace($mask)
{
    $mask &= 0x7ff;
    // Return zero if for all class (or for none
    if ($mask == 0x7ff or $mask == 0) {
        return 0;
    }
    return getListFromArray_1(getRaceNames(), $mask);
}