소스 검색

Add difficulty_class to dice.

Sam Jaffe 4 년 전
부모
커밋
e3538e45da
1개의 변경된 파일3개의 추가작업 그리고 2개의 파일을 삭제
  1. 3 2
      include/dice-roll/die.h

+ 3 - 2
include/dice-roll/die.h

@@ -37,8 +37,8 @@ struct difficulty_class {
   
   bool operator()(int value) const;
   
-  test comp;
-  int against;
+  test comp{test::None};
+  int against{0};
 };
 
 // Default value: 1{+0}
@@ -46,6 +46,7 @@ struct dice {
   int num{1};
   std::vector<die> of{};
   std::vector<mod> modifier{+0};
+  difficulty_class dc{};
 };
 
 /**