Add commander brackets support in deck editor and new game dialog
- Dominant language
- Java
- Stars
- 2.4k
- Forks
- 940
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 160
Description
Some days ago [wizards presented commander brackets system (reddit summary)](https://www.reddit.com/r/magicTCG/comments/1in53q7/comment/mc81xp7/) to rank player's decks.

The main idea: analyse decks same way as legality checks does -- so users can see commander brackets level of their deck. If it will works fine then such filter/requirements can be added to game table/tourney dialogs, so users can check/limit opponent's decks without deck discloses (current users can limit decks by edh levels/points but it's a hidden and non-intuitive feature).
Brackets system must be implemented same as [edh power levels](https://edhpowerlevel.com/) -- each deck must be analysed to search and calc cards with specific abilities/effects. Old edh implementation uses text search only (see [AbstractCommander->getEdhPowerLevel](https://github.com/magefree/mage/blob/ba0e5a1aed360b3ba066dafba6d93aa06cd69aab/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/AbstractCommander.java#L261)). But new implementation can use abilities search, not text only.
It's not fully automated feature, but can find out 95% of all use cases. Moxfield has useful tools to find out and check cards/decks for specific bracket level: https://moxfield.com/commanderbrackets
Features to implement:
* [x] code: add deck analyse feature to find commander bracket level;
* [ ] tests: add some example decks from each level to make sure xmage's bracket system can find correct level;
* [x] gui: add bracket level info in deck editor (as part of legality check - as 5 level buttons, so users can select cards from 4 level as example);
* [ ] gui: add max bracket limit to new table/tourney dialog (can be added to custom options, default is 5);

Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.