diff options
author | Daniel <kingdread@gmx.de> | 2020-05-04 15:25:33 +0200 |
---|---|---|
committer | Daniel <kingdread@gmx.de> | 2020-05-04 15:25:33 +0200 |
commit | 74dc6574650a157ab57779dc633e140d020b792a (patch) | |
tree | 6543a81e0545b9acfeea64a63547c0f7aadf996c /src/playerclass.rs | |
parent | 6afe5879579ad39397024fbdbe75ad3207ff50a1 (diff) | |
download | raidgrep-74dc6574650a157ab57779dc633e140d020b792a.tar.gz raidgrep-74dc6574650a157ab57779dc633e140d020b792a.tar.bz2 raidgrep-74dc6574650a157ab57779dc633e140d020b792a.zip |
add -class player filter
Diffstat (limited to 'src/playerclass.rs')
-rw-r--r-- | src/playerclass.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/playerclass.rs b/src/playerclass.rs index 77b9794..247e8b1 100644 --- a/src/playerclass.rs +++ b/src/playerclass.rs @@ -59,6 +59,12 @@ impl From<(Profession, Option<EliteSpec>)> for PlayerClass { } } +impl From<&evtclib::Player> for PlayerClass { + fn from(player: &evtclib::Player) -> Self { + (player.profession(), player.elite()).into() + } +} + impl fmt::Display for PlayerClass { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { use EliteSpec::*; |