Change the parameter type of ModeHandler::GiveModeList() from ModeMasks to ModeType
Replace ModeMasks with a two-dimensional array