Class: BCDice::CommonCommand::BarabaraDice::Result
- Defined in:
- lib/bcdice/common_command/barabara_dice/result.rb
Overview
バラバラロールの結果を表すクラス
Instance Attribute Summary collapse
-
#last_dice_list ⇒ Array<Integer>
すべての出目が格納される配列.
-
#last_dice_list_list ⇒ Array<Array<Integer>>
出目のグループの配列.
-
#success_num ⇒ Integer
成功数.
Attributes inherited from Result
#critical, #detailed_rands, #failure, #fumble, #rands, #secret, #success, #text
Instance Method Summary collapse
-
#initialize(text = nil) ⇒ Result
constructor
A new instance of Result.
Methods inherited from Result
#condition=, critical, #critical?, failure, #failure?, fumble, #fumble?, nothing, #secret?, success, #success?
Constructor Details
#initialize(text = nil) ⇒ Result
Returns a new instance of Result.
18 19 20 21 22 23 24 |
# File 'lib/bcdice/common_command/barabara_dice/result.rb', line 18 def initialize(text = nil) super(text) @last_dice_list_list = [] @last_dice_list = [] @success_num = 0 end |
Instance Attribute Details
#last_dice_list ⇒ Array<Integer>
Returns すべての出目が格納される配列.
13 14 15 |
# File 'lib/bcdice/common_command/barabara_dice/result.rb', line 13 def last_dice_list @last_dice_list end |
#last_dice_list_list ⇒ Array<Array<Integer>>
Returns 出目のグループの配列.
11 12 13 |
# File 'lib/bcdice/common_command/barabara_dice/result.rb', line 11 def last_dice_list_list @last_dice_list_list end |
#success_num ⇒ Integer
Returns 成功数.
15 16 17 |
# File 'lib/bcdice/common_command/barabara_dice/result.rb', line 15 def success_num @success_num end |