The bug I found here is when Dragon with subrace, lets say 10, will have its race set to Ele (which only has 4 subraces), then the mud crashed. I will include the fix in the next pull request. :)