Move classAttr functions to separate file

Also hotfix for infinite loop in character creation code
Merge branch 'master' of github.com:nyaccino/text-rpg