12-18-2014, 10:24 PM
Don't generate a min-max check (because it will fail for MonsterType anyway, it has "holes" in the values range), generate a switch-check - one big switch with a case for each value, and a default printing an error. The only problem here is multiple aliases for the same value, we'll probably have to solve that one somehow (a new comment, "// tolua-ignoreenum"? )